diff options
Diffstat (limited to 'gprof')
-rw-r--r-- | gprof/ChangeLog | 6 | ||||
-rw-r--r-- | gprof/gprof.c | 3 | ||||
-rw-r--r-- | gprof/sym_ids.c | 7 |
3 files changed, 12 insertions, 4 deletions
diff --git a/gprof/ChangeLog b/gprof/ChangeLog index dc983984274..5b8b0b760ca 100644 --- a/gprof/ChangeLog +++ b/gprof/ChangeLog @@ -1,3 +1,9 @@ +2001-09-18 Bruno Haible <haible@clisp.cons.org> + + * gprof.c (main): For gettext, also set the LC_CTYPE locate facet. + * sym_ids.c: Include "safe-ctype.h" instead of <ctype.h>. + (parse_spec): Use ISDIGIT instead of isdigit. + 2001-09-18 Alan Modra <amodra@bigpond.net.au> * sparc.c (sparc_find_call): Warning fix. diff --git a/gprof/gprof.c b/gprof/gprof.c index 2ed37a3f9c6..4a1fd50d01d 100644 --- a/gprof/gprof.c +++ b/gprof/gprof.c @@ -173,6 +173,9 @@ DEFUN (main, (argc, argv), int argc AND char **argv) #if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES) setlocale (LC_MESSAGES, ""); #endif +#if defined (HAVE_SETLOCALE) + setlocale (LC_CTYPE, ""); +#endif bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); diff --git a/gprof/sym_ids.c b/gprof/sym_ids.c index f98ccbfe55c..bf6ffcd054b 100644 --- a/gprof/sym_ids.c +++ b/gprof/sym_ids.c @@ -19,9 +19,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include <ctype.h> - #include "libiberty.h" +#include "safe-ctype.h" #include "cg_arcs.h" #include "sym_ids.h" @@ -123,7 +122,7 @@ DEFUN (parse_spec, (spec, sym), char *spec AND Sym * sym) if (strlen (spec)) { - if (isdigit ((unsigned char) spec[0])) + if (ISDIGIT (spec[0])) sym->line_num = atoi (spec); else sym->name = spec; @@ -139,7 +138,7 @@ DEFUN (parse_spec, (spec, sym), char *spec AND Sym * sym) if (!sym->file) sym->file = &non_existent_file; } - else if (isdigit ((unsigned char) *spec)) + else if (ISDIGIT (*spec)) { sym->line_num = atoi (spec); } |