Fixed double free introduced with rev 1233.
This commit is contained in:
parent
505bf23aa4
commit
c6aedc9eb5
@ -1747,10 +1747,13 @@ int rrip_get_susp_fields(Ecma119Image *t, Ecma119Node *n, int type,
|
||||
|
||||
namelen = 0;
|
||||
name = get_rr_fname(t, n->node->name);
|
||||
if (name != NULL) {
|
||||
namelen = strlen(name);
|
||||
free(name);
|
||||
if (name == NULL)
|
||||
name = strdup("");
|
||||
if (name == NULL) {
|
||||
ret = ISO_OUT_OF_MEM;
|
||||
goto add_susp_cleanup;
|
||||
}
|
||||
namelen = strlen(name);
|
||||
sua_free = space - info->suf_len;
|
||||
|
||||
/* Try whether NM, SL, AL will fit into SUA */
|
||||
@ -2136,6 +2139,7 @@ int rrip_get_susp_fields(Ecma119Image *t, Ecma119Node *n, int type,
|
||||
return ISO_SUCCESS;
|
||||
|
||||
add_susp_cleanup: ;
|
||||
if (name != NULL)
|
||||
free(name);
|
||||
if (dest != NULL)
|
||||
free(dest);
|
||||
|
Loading…
x
Reference in New Issue
Block a user