Hi,

* Ivan Skytte Jørgensen wrote (2007-10-15 22:52):
>diff -r -U3 nedit.isj6/source/tags.c nedit.isj7/source/tags.c
>--- nedit.isj6/source/tags.c    2007-03-05 00:26:05.000000000 +0100
>+++ nedit.isj7/source/tags.c    2007-10-15 22:47:47.000000000 +0200
>@@ -1218,6 +1218,7 @@
>                 sprintf(temp,"%2d. %s%s",i+1,pathname,filename);
>             if (!(dupTagsList[i] = (char *) malloc(strlen(temp) + 1))) {
>                 fprintf(stderr, "NEdit: findDef(): out of heap space!\n");
>+                free(dupTagsList);
>                 XBell(TheDisplay, 0);
>                 return -1;
>             }

Shouldn't we unroll the for loop? There may already be malloced matches.


Thorsten
-- 
Wise men make proverbs, but fools repeat them.
    - Samuel Palmer

Attachment: pgpDEQaMvdOXg.pgp
Description: PGP signature

-- 
NEdit Develop mailing list - [email protected]
http://www.nedit.org/mailman/listinfo/develop

Reply via email to