diff options
author | phantom <phantom@FreeBSD.org> | 2000-09-01 11:56:31 +0000 |
---|---|---|
committer | phantom <phantom@FreeBSD.org> | 2000-09-01 11:56:31 +0000 |
commit | 3fd2030fc48edebae9203e4245f795543e5cbb66 (patch) | |
tree | 9d193f39f39a99f0fbb74215bf53a3fe48bcbc0e /lib | |
parent | 8ac9a8d4cd024ace6052923c706acb19c53efab7 (diff) | |
download | FreeBSD-src-3fd2030fc48edebae9203e4245f795543e5cbb66.zip FreeBSD-src-3fd2030fc48edebae9203e4245f795543e5cbb66.tar.gz |
Fix memory leak introduced by kris in rev 1.22
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/nls/msgcat.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/libc/nls/msgcat.c b/lib/libc/nls/msgcat.c index f02af8e..ebbac70 100644 --- a/lib/libc/nls/msgcat.c +++ b/lib/libc/nls/msgcat.c @@ -134,6 +134,7 @@ int type; if (*(nlspath + 1) == 'L') { ++nlspath; if (strlcpy(pathP, lang, spcleft) >= spcleft) { + free(base); errno = ENAMETOOLONG; return(NLERR); } @@ -141,6 +142,7 @@ int type; } else if (*(nlspath + 1) == 'N') { ++nlspath; if (strlcpy(pathP, name, spcleft) >= spcleft) { + free(base); errno = ENAMETOOLONG; return(NLERR); } |