libblkid Reference Manual | ||||
---|---|---|---|---|
Top | Description |
int blkid_encode_string (const char *str
,char *str_enc
,size_t len
); int blkid_safe_string (const char *str
,char *str_safe
,size_t len
);
int blkid_encode_string (const char *str
,char *str_enc
,size_t len
);
Encode all potentially unsafe characters of a string to the corresponding hex value prefixed by '\x'.
|
input string to be encoded |
|
output string to store the encoded input string |
|
maximum size of the output string, which may be four times as long as the input string |
Returns : |
0 if the entire string was copied, non-zero otherwise. |