From df49e23bcf44f47a435a4c77c828e5b3d2c3e676 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sun, 8 Nov 2015 16:34:59 +0000 Subject: [PATCH] Corrected interpretation of some return values during -find -exec list_extattr. Coverity CID 28704. --- xorriso/iso_tree.c | 11 ++++++++--- xorriso/xorriso_timestamp.h | 2 +- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/xorriso/iso_tree.c b/xorriso/iso_tree.c index 769e065b..dec0fef1 100644 --- a/xorriso/iso_tree.c +++ b/xorriso/iso_tree.c @@ -1013,15 +1013,20 @@ int Xorriso_list_extattr(struct XorrisO *xorriso, void *in_node, char *path, break; if((size_t) (upt - uval) < value_lengths[i]) { strcpy(line, "echo 'OMITTED: Value contains 0-bytes : space \"'\""); - Xorriso_append_extattr_comp(xorriso, space_pt, strlen(space_pt), "e", 1); + ret= Xorriso_append_extattr_comp(xorriso, space_pt, strlen(space_pt), + "e", 1); if(ret <= 0) goto ex; strcat(line, "\"'\" , name \"'\""); - Xorriso_append_extattr_comp(xorriso, name_pt, strlen(name_pt), "e", 1); + ret= Xorriso_append_extattr_comp(xorriso, name_pt, strlen(name_pt), + "e", 1); if(ret <= 0) goto ex; strcat(line, "\"'\" in file '\""); - Xorriso_append_extattr_comp(xorriso, path_pt, strlen(path_pt), "e", 1); + ret= Xorriso_append_extattr_comp(xorriso, path_pt, strlen(path_pt), + "e", 1); + if(ret <= 0) + goto ex; strcat(line, "\" >&2\n"); /* temporarily disable -backslash_codes with result output */ diff --git a/xorriso/xorriso_timestamp.h b/xorriso/xorriso_timestamp.h index 0793763b..edc7a3bd 100644 --- a/xorriso/xorriso_timestamp.h +++ b/xorriso/xorriso_timestamp.h @@ -1 +1 @@ -#define Xorriso_timestamP "2015.11.08.161658" +#define Xorriso_timestamP "2015.11.08.163431"