Reacted on compiler warnings about rev 5601

This commit is contained in:
Thomas Schmitt 2015-11-12 14:27:16 +00:00
parent 17ba65b8b6
commit d5c18dcbbf
2 changed files with 5 additions and 3 deletions

View File

@ -894,7 +894,8 @@ int Xorriso_append_extattr_comp(struct XorrisO *xorriso,
char *comp, size_t comp_len, char *comp, size_t comp_len,
char *mode, int flag) char *mode, int flag)
{ {
int ret, line_limit; int ret;
size_t line_limit;
char *line, *wpt, *bsl = NULL; char *line, *wpt, *bsl = NULL;
unsigned char *upt, *uval; unsigned char *upt, *uval;
@ -914,7 +915,8 @@ int Xorriso_append_extattr_comp(struct XorrisO *xorriso,
strcat(line, "\"$(echo -e '"); strcat(line, "\"$(echo -e '");
wpt= line + strlen(line); wpt= line + strlen(line);
for(upt= uval; (size_t) (upt - uval) < comp_len; upt++) { for(upt= uval; (size_t) (upt - uval) < comp_len; upt++) {
if(wpt - line + 5 + 3 + 1 > line_limit) /* "\\0xyz" + "')\"" + 0 */ if(wpt - line + 5 + 3 + 1 > (ssize_t) line_limit)
/* "\\0xyz" + "')\"" + 0 */
goto too_much; goto too_much;
if(*upt <= 037 || *upt >= 0177 || *upt == '\\' || *upt == '\'') { if(*upt <= 037 || *upt >= 0177 || *upt == '\\' || *upt == '\'') {
if(flag & 1) if(flag & 1)

View File

@ -1 +1 @@
#define Xorriso_timestamP "2015.11.12.123345" #define Xorriso_timestamP "2015.11.12.142649"