aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2001-08-08 18:52:29 +0000
committerUlrich Drepper <drepper@redhat.com>2001-08-08 18:52:29 +0000
commit443470c3360d5d4ffb8f3078f47cda55fd5cffbd (patch)
tree84f2e47a423fec132158486117ec6742fc1c6418
parent121f86f245cf88687b52ca17f79e613d9fbdba23 (diff)
downloadglibc-443470c3360d5d4ffb8f3078f47cda55fd5cffbd.tar
glibc-443470c3360d5d4ffb8f3078f47cda55fd5cffbd.tar.gz
glibc-443470c3360d5d4ffb8f3078f47cda55fd5cffbd.tar.bz2
glibc-443470c3360d5d4ffb8f3078f47cda55fd5cffbd.zip
Update.
for CRNCYSTR. * locale/programs/ld-monetary.c (monetary_finish): Likewise. functionality. call me(). If in the middle of initializing, return NULL or * manual/locale.texi: Add documentation for rpmatch.
-rw-r--r--ChangeLog9
-rw-r--r--locale/programs/ld-monetary.c45
2 files changed, 26 insertions, 28 deletions
diff --git a/ChangeLog b/ChangeLog
index cd8297e855..e3473c891f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,11 +1,12 @@
2001-08-08 Ulrich Drepper <drepper@redhat.com>
* locale/C-monetary.c (_nl_C_LC_MONETARY): Provide correct value
- of CRNCYSTR.
+ for CRNCYSTR.
* locale/programs/ld-messages.c (messages_finish): Provide POSIX
locale compliant default values for fields without definition.
* locale/programs/ld-time.c (time_finish): Likewise.
+ * locale/programs/ld-monetary.c (monetary_finish): Likewise.
2001-08-08 Andreas Jaeger <aj@suse.de>
@@ -15,7 +16,7 @@
2001-08-07 Ulrich Drepper <drepper@redhat.com>
* sysdeps/ia64/memusage.h (GETTIME): Define using hp-timing.h
- funcationality.
+ functionality.
* sysdeps/ia64/hp-timing.h (HP_TIMING_NOW): Fix comment.
@@ -25,7 +26,7 @@
(init): If not yet initialized, call me().
(me): Do all dlsym calls here.
(malloc, realloc, calloc, free): If not yet initialized,
- call me(). If in the middle of initializing, return NULL or
+ call me(). If in the middle of initializing, return NULL or
do nothing.
2001-08-07 Jakub Jelinek <jakub@redhat.com>
@@ -64,7 +65,7 @@
2001-08-06 Ulrich Drepper <drepper@redhat.com>
- * manual/locale.texi: Add documentation of rpmatch.
+ * manual/locale.texi: Add documentation for rpmatch.
Patch by Jochen Hein <jochen@jochen.org>.
2001-08-06 Jakub Jelinek <jakub@redhat.com>
diff --git a/locale/programs/ld-monetary.c b/locale/programs/ld-monetary.c
index aa20c5203e..08a10fdcc1 100644
--- a/locale/programs/ld-monetary.c
+++ b/locale/programs/ld-monetary.c
@@ -199,21 +199,21 @@ monetary_finish (struct localedef_t *locale, struct charmap_t *charmap)
}
}
-#define TEST_ELEM(cat) \
+#define TEST_ELEM(cat, initval) \
if (monetary->cat == NULL) \
{ \
if (! be_quiet && ! nothing) \
error (0, 0, _("%s: field `%s' not defined"), \
"LC_MONETARY", #cat); \
- monetary->cat = ""; \
+ monetary->cat = initval; \
}
- TEST_ELEM (int_curr_symbol);
- TEST_ELEM (currency_symbol);
- TEST_ELEM (mon_decimal_point);
- TEST_ELEM (mon_thousands_sep);
- TEST_ELEM (positive_sign);
- TEST_ELEM (negative_sign);
+ TEST_ELEM (int_curr_symbol, "");
+ TEST_ELEM (currency_symbol, "");
+ TEST_ELEM (mon_decimal_point, ".");
+ TEST_ELEM (mon_thousands_sep, "");
+ TEST_ELEM (positive_sign, "");
+ TEST_ELEM (negative_sign, "");
/* The international currency symbol must come from ISO 4217. */
if (monetary->int_curr_symbol != NULL)
@@ -243,7 +243,7 @@ not correspond to a valid name in ISO 4217"),
if (! be_quiet && ! nothing)
error (0, 0, _("%s: field `%s' not defined"),
"LC_MONETARY", "mon_decimal_point");
- monetary->mon_decimal_point = "";
+ monetary->mon_decimal_point = ".";
}
else if (monetary->mon_decimal_point[0] == '\0' && ! be_quiet && ! nothing)
{
@@ -265,31 +265,28 @@ not correspond to a valid name in ISO 4217"),
}
#undef TEST_ELEM
-#define TEST_ELEM(cat, min, max) \
+#define TEST_ELEM(cat, min, max, initval) \
if (monetary->cat == -2) \
{ \
if (! be_quiet && ! nothing) \
error (0, 0, _("%s: field `%s' not defined"), \
"LC_MONETARY", #cat); \
+ monetary->cat = initval; \
} \
- else if ((monetary->cat < min || monetary->cat > max) && !be_quiet \
- && !nothing) \
+ else if ((monetary->cat < min || monetary->cat > max) \
+ && !be_quiet && !nothing) \
error (0, 0, _(" \
%s: value for field `%s' must be in range %d...%d"), \
"LC_MONETARY", #cat, min, max)
-#if 0
-/* The following two test are not really necessary because all values
- the variable could have are valid. */
- TEST_ELEM (int_frac_digits, -128, 127); /* No range check. */
- TEST_ELEM (frac_digits, -128, 127); /* No range check. */
-#endif
- TEST_ELEM (p_cs_precedes, -1, 1);
- TEST_ELEM (p_sep_by_space, -1, 2);
- TEST_ELEM (n_cs_precedes, -1, 1);
- TEST_ELEM (n_sep_by_space, -1, 2);
- TEST_ELEM (p_sign_posn, -1, 4);
- TEST_ELEM (n_sign_posn, -1, 4);
+ TEST_ELEM (int_frac_digits, -128, 127, -1);
+ TEST_ELEM (frac_digits, -128, 127, -1);
+ TEST_ELEM (p_cs_precedes, -1, 1, -1);
+ TEST_ELEM (p_sep_by_space, -1, 2, -1);
+ TEST_ELEM (n_cs_precedes, -1, 1, -1);
+ TEST_ELEM (n_sep_by_space, -1, 2, -1);
+ TEST_ELEM (p_sign_posn, -1, 4, -1);
+ TEST_ELEM (n_sign_posn, -1, 4, -1);
/* The non-POSIX.2 extensions are optional. */
if (monetary->duo_int_curr_symbol == NULL)