diff options
author | Ulrich Drepper <drepper@redhat.com> | 2001-08-09 22:37:19 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2001-08-09 22:37:19 +0000 |
commit | 30d13751354ba7eeabbce754b06650b99884c3c3 (patch) | |
tree | 8d7a4dfa2a0a2073470833c5b1bdfd012f66fca8 /catgets/catgets.c | |
parent | 5d9f13dc9b97a22c614ad5ad7b1a22eacc626acd (diff) | |
download | glibc-30d13751354ba7eeabbce754b06650b99884c3c3.tar.gz |
Update.
2001-08-09 Jakub Jelinek <jakub@redhat.com>
* catgets/catgets.c (catclose): Be liberal about catalog_desc in
catclose too.
* time/tst-strptime.c: Add test case for %U and %W handling.
Diffstat (limited to 'catgets/catgets.c')
-rw-r--r-- | catgets/catgets.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/catgets/catgets.c b/catgets/catgets.c index 248b552c91..b11cc597b3 100644 --- a/catgets/catgets.c +++ b/catgets/catgets.c @@ -114,6 +114,13 @@ catclose (nl_catd catalog_desc) { __nl_catd catalog; + /* Be generous if catalog which failed to be open is used. */ + if (catalog_desc == (nl_catd) -1) + { + __set_errno (EBADF); + return -1; + } + catalog = (__nl_catd) catalog_desc; #ifdef _POSIX_MAPPED_FILES |