dtappbuilder: Further coverity, resource leaks, copy intofixed size buffer and dereference before null checl
This commit is contained in:
@@ -446,6 +446,7 @@ istrP_create_alloced_impl(
|
||||
fprintf(stderr, "%s",
|
||||
catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
|
||||
"ISTR: error in allocating space for string\n") );
|
||||
free(new_bucket);
|
||||
return NULL;
|
||||
}
|
||||
new_bucket->values[0] = freelist[freecount-1];
|
||||
@@ -625,6 +626,7 @@ istr_create_const(
|
||||
fprintf(stderr, "%s",
|
||||
catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
|
||||
"ISTR: error in allocating space for string\n") );
|
||||
free(new_bucket);
|
||||
return NULL;
|
||||
}
|
||||
new_bucket->values[0] = freelist[freecount-1];
|
||||
|
||||
@@ -641,6 +641,8 @@ strlistP_grow_array(StringList list, int sizeDiff)
|
||||
if ((new_strings == NULL) || (new_user_datas == NULL))
|
||||
{
|
||||
return_value = -1;
|
||||
free(new_strings);
|
||||
free(new_user_datas);
|
||||
goto epilogue;
|
||||
}
|
||||
else
|
||||
|
||||
@@ -563,6 +563,7 @@ util_derive_name_from_path(
|
||||
len = strlen(name) - (AB_EXT_LENGTH + 1);
|
||||
strncpy(objname, name, len);
|
||||
objname[len] = '\0';
|
||||
free(name);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user