diff options
author | Alexey Zelkin <phantom@FreeBSD.org> | 2000-09-01 11:56:31 +0000 |
---|---|---|
committer | Alexey Zelkin <phantom@FreeBSD.org> | 2000-09-01 11:56:31 +0000 |
commit | a367b9700f4853d07195f9ab94df2c28c81807d7 (patch) | |
tree | 0e27df6a90b649f81061d2a48881c6b95904cecb /lib/libc/nls | |
parent | d85a56345e3e3f8abeea79d519ee30a23a8e782c (diff) | |
download | src-a367b9700f4853d07195f9ab94df2c28c81807d7.tar.gz src-a367b9700f4853d07195f9ab94df2c28c81807d7.zip |
Fix memory leak introduced by kris in rev 1.22
Notes
Notes:
svn path=/head/; revision=65323
Diffstat (limited to 'lib/libc/nls')
-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 f02af8e0ae4c..ebbac70f5074 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); } |