summaryrefslogtreecommitdiff
path: root/locale
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2008-04-08 07:59:52 +0000
committerJakub Jelinek <jakub@redhat.com>2008-04-08 07:59:52 +0000
commite6e467b8352b6a62b8187fd241671eb55d0f6fc4 (patch)
tree2e7c2ddae1aa58a70c384e1d5b49d3ad198a2718 /locale
parent09b731ac2b1b5e79050991f6a9dab964f9a7a60f (diff)
Updated to fedora-glibc-20080408T0706
Diffstat (limited to 'locale')
-rw-r--r--locale/duplocale.c8
-rw-r--r--locale/freelocale.c8
-rw-r--r--locale/newlocale.c10
-rw-r--r--locale/programs/ld-time.c4
-rw-r--r--locale/programs/locfile.c4
-rw-r--r--locale/setlocale.c12
6 files changed, 23 insertions, 23 deletions
diff --git a/locale/duplocale.c b/locale/duplocale.c
index 0cec09f63a..61782590d7 100644
--- a/locale/duplocale.c
+++ b/locale/duplocale.c
@@ -1,5 +1,5 @@
/* Duplicate handle for selection of locales.
- Copyright (C) 1997, 2000, 2001, 2002, 2005 Free Software Foundation, Inc.
+ Copyright (C) 1997,2000,2001,2002,2005,2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
@@ -27,7 +27,7 @@
/* Lock for protecting global data. */
-__libc_lock_define (extern , __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define (extern , __libc_setlocale_lock attribute_hidden)
__locale_t
@@ -54,7 +54,7 @@ __duplocale (__locale_t dataset)
char *namep = (char *) (result + 1);
/* We modify global data (the usage counts). */
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
for (cnt = 0; cnt < __LC_LAST; ++cnt)
if (cnt != LC_ALL)
@@ -78,7 +78,7 @@ __duplocale (__locale_t dataset)
result->__ctype_toupper = dataset->__ctype_toupper;
/* It's done. */
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
}
return result;
diff --git a/locale/freelocale.c b/locale/freelocale.c
index 7430455d56..97a8ee8a5e 100644
--- a/locale/freelocale.c
+++ b/locale/freelocale.c
@@ -1,5 +1,5 @@
/* Free data allocated by a call to setlocale_r
- Copyright (C) 1996, 1997, 2000, 2002, 2005 Free Software Foundation, Inc.
+ Copyright (C) 1996,1997,2000,2002,2005,2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
@@ -26,7 +26,7 @@
/* Lock for protecting global data. */
-__libc_lock_define (extern , __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define (extern , __libc_setlocale_lock attribute_hidden)
void
@@ -39,7 +39,7 @@ __freelocale (__locale_t dataset)
return;
/* We modify global data (the usage counts). */
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
for (cnt = 0; cnt < __LC_LAST; ++cnt)
if (cnt != LC_ALL && dataset->__locales[cnt]->usage_count != UNDELETABLE)
@@ -47,7 +47,7 @@ __freelocale (__locale_t dataset)
_nl_remove_locale (cnt, dataset->__locales[cnt]);
/* It's done. */
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
/* Free the locale_t handle itself. */
free (dataset);
diff --git a/locale/newlocale.c b/locale/newlocale.c
index 0c31ba48ae..da142f2912 100644
--- a/locale/newlocale.c
+++ b/locale/newlocale.c
@@ -1,5 +1,5 @@
/* Return a reference to locale information record.
- Copyright (C) 1996, 1997, 1999, 2000-2002, 2004, 2005, 2006
+ Copyright (C) 1996, 1997, 1999, 2000-2002, 2004, 2005, 2006, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
@@ -30,7 +30,7 @@
/* Lock for protecting global data. */
-__libc_lock_define (extern , __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define (extern , __libc_setlocale_lock attribute_hidden)
/* Use this when we come along an error. */
@@ -162,7 +162,7 @@ __newlocale (int category_mask, const char *locale, __locale_t base)
}
/* Protect global data. */
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
/* Now process all categories we are interested in. */
names_len = 0;
@@ -183,7 +183,7 @@ __newlocale (int category_mask, const char *locale, __locale_t base)
_nl_remove_locale (cnt, result.__locales[cnt]);
/* Critical section left. */
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
return NULL;
}
@@ -263,7 +263,7 @@ __newlocale (int category_mask, const char *locale, __locale_t base)
}
/* Critical section left. */
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
/* Update the special members. */
update:
diff --git a/locale/programs/ld-time.c b/locale/programs/ld-time.c
index f040c93474..3a00d26f30 100644
--- a/locale/programs/ld-time.c
+++ b/locale/programs/ld-time.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-2005, 2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1995-2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.org>, 1995.
@@ -433,7 +433,7 @@ No definition for %s category found"), "LC_TIME"));
&& !__isleap (time->era_entries[idx].stop_date[0])))
&& !be_quiet)
WITH_CUR_LOCALE (error (0, 0, _("\
-%s: stopping date is invalid in string %Zd in `era' field"),
+%s: invalid stopping date in string %Zd in `era' field"),
"LC_TIME", idx + 1));
}
}
diff --git a/locale/programs/locfile.c b/locale/programs/locfile.c
index 17cd0209a4..928048b377 100644
--- a/locale/programs/locfile.c
+++ b/locale/programs/locfile.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996-2004, 2005, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1996-2004, 2005, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.org>, 1996.
@@ -779,7 +779,7 @@ handle_copy (struct linereader *ldfile, const struct charmap_t *charmap,
now = lr_token (ldfile, charmap, result, NULL, verbose);
if (now->tok != tok_string)
- lr_error (ldfile, _("expect string argument for `copy'"));
+ lr_error (ldfile, _("expecting string argument for `copy'"));
else if (!ignore_content)
{
if (now->val.str.startmb == NULL)
diff --git a/locale/setlocale.c b/locale/setlocale.c
index c1b8c3faec..767a5aab6b 100644
--- a/locale/setlocale.c
+++ b/locale/setlocale.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 1992, 1995-2000, 2002, 2003, 2004, 2006
+/* Copyright (C) 1991, 1992, 1995-2000, 2002, 2003, 2004, 2006, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -123,7 +123,7 @@ static void (*const _nl_category_postload[]) (void) =
/* Lock for protecting global data. */
-__libc_lock_define_initialized (, __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define_initialized (, __libc_setlocale_lock attribute_hidden)
/* Defined in loadmsgcat.c. */
extern int _nl_msg_cat_cntr;
@@ -314,7 +314,7 @@ setlocale (int category, const char *locale)
}
/* Protect global data. */
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
/* Load the new data for each category. */
while (category-- > 0)
@@ -381,7 +381,7 @@ setlocale (int category, const char *locale)
free ((char *) newnames[category]);
/* Critical section left. */
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
/* Free the resources (the locale path variable). */
free (locale_path);
@@ -394,7 +394,7 @@ setlocale (int category, const char *locale)
const char *newname[1] = { locale };
/* Protect global data. */
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
if (CATEGORY_USED (category))
{
@@ -446,7 +446,7 @@ setlocale (int category, const char *locale)
}
/* Critical section left. */
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
/* Free the resources (the locale path variable. */
free (locale_path);