Skip to content

Commit

Permalink
Fix _NC_LOCALE_NAME definition.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ulrich Drepper committed Nov 17, 2009
1 parent 2866eeb commit 4fb9241
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
2009-11-17 Ulrich Drepper <drepper@redhat.com>

[BZ #10968]
* locale/langinfo.h (_NL_LOCALE_NAME): Correct definition.
Patch by Bruno Haible <bruno@clisp.org>.
* locale/tst-locname.c: New file.
* locale/Makefile (tests): Add tst-locname.

[BZ #10972]
* sysdeps/unix/sysv/linux/powerpc/bits/mman.h: Add new MADV_*
constants from recent kernels.
Expand Down
6 changes: 3 additions & 3 deletions locale/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (C) 1991,1992,1995-2003,2005 Free Software Foundation, Inc.
# Copyright (C) 1991,1992,1995-2003,2005,2009 Free Software Foundation, Inc.
# This file is part of the GNU C Library.

# The GNU C Library is free software; you can redistribute it and/or
Expand Down Expand Up @@ -38,7 +38,7 @@ distribute = localeinfo.h categories.def iso-639.def iso-3166.def \
routines = setlocale findlocale loadlocale loadarchive \
localeconv nl_langinfo nl_langinfo_l mb_cur_max \
newlocale duplocale freelocale uselocale
tests = tst-C-locale
tests = tst-C-locale tst-locname
categories = ctype messages monetary numeric time paper name \
address telephone measurement identification collate
aux = $(categories:%=lc-%) $(categories:%=C-%) SYS_libc C_name \
Expand Down Expand Up @@ -104,7 +104,7 @@ CFLAGS-charmap-dir.c = -Wno-write-strings

# This makes sure -DNOT_IN_libc is passed for all these modules.
cpp-srcs-left := $(addsuffix .c,$(localedef-modules) $(localedef-aux) \
$(locale-modules) $(lib-modules))
$(locale-modules) $(lib-modules))
lib := nonlib
include $(patsubst %,$(..)cppflags-iterator.mk,$(cpp-srcs-left))

Expand Down
3 changes: 2 additions & 1 deletion locale/langinfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,8 @@ enum

/* This macro produces an item you can pass to `nl_langinfo' or
`nl_langinfo_l' to get the name of the locale in use for CATEGORY. */
#define _NL_LOCALE_NAME(category) _NL_ITEM ((category), -1)
#define _NL_LOCALE_NAME(category) _NL_ITEM ((category), \
_NL_ITEM_INDEX (-1))
#ifdef __USE_GNU
# define NL_LOCALE_NAME(category) _NL_LOCALE_NAME (category)
#endif
Expand Down

0 comments on commit 4fb9241

Please sign in to comment.