Update.
* locale/loadlocale.c (_nl_load_locale): Don't allow too small files crash the program. * string/Makefile: Don't run test on tst-svc.out if cross-compiling.
This commit is contained in:
parent
e7a95dc622
commit
6e607d847c
@ -1,8 +1,10 @@
|
||||
1998-05-29 Ulrich Drepper <drepper@cygnus.com>
|
||||
|
||||
* locale/loadlocale.c (_nl_load_locale): Don't allow too small
|
||||
files crash the program.
|
||||
|
||||
* io/Makefile: Don't run ftwtest-sh if cross-compiling.
|
||||
* string/Makefile: Don't run test on tst/svc.out if
|
||||
cross-compiling.
|
||||
* string/Makefile: Don't run test on tst-svc.out if cross-compiling.
|
||||
Reported by Deborah Wallach <kerr@pa.dec.com>.
|
||||
|
||||
1998-05-28 00:53 Zack Weinberg <zack@rabi.phys.columbia.edu>
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* Functions to read locale data files.
|
||||
Copyright (C) 1996, 1997 Free Software Foundation, Inc.
|
||||
Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1996.
|
||||
|
||||
@ -160,6 +160,9 @@ _nl_load_locale (struct loaded_l10nfile *file, int category)
|
||||
else
|
||||
goto puntfd;
|
||||
}
|
||||
else if (st.st_size < sizeof (*filedata))
|
||||
/* This cannot be a locale data file since it's too small. */
|
||||
goto puntfd;
|
||||
|
||||
if (filedata->magic == LIMAGIC (category))
|
||||
/* Good data file in our byte order. */
|
||||
|
Loading…
x
Reference in New Issue
Block a user