aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--localedata/ChangeLog7
-rw-r--r--localedata/SUPPORTED2
-rw-r--r--localedata/locales/ku_TR215
-rw-r--r--stdlib/Makefile3
-rw-r--r--stdlib/tst-ucontext-off.c35
-rw-r--r--sysdeps/unix/sysv/linux/i386/ucontext_i.h22
-rw-r--r--sysdeps/unix/sysv/linux/x86_64/ucontext_i.h32
-rw-r--r--time/bug-asctime_r.c6
9 files changed, 320 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index 73ea01bf52..6455a968c1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2005-10-14 Ulrich Drepper <drepper@redhat.com>
+ [BZ #1468]
+ * sysdeps/unix/sysv/linux/x86_64/ucontext_i.h: Fix values for
+ oFPREGS, oSIGMASK, oFPREGSMEM, and oMXCSR.
+ Patch by Nicholas Miell <nmiell@comcast.net>.
+
[BZ #1460]
* time/asctime.c (asctime_internal): New function, derived from
asctime_r. Takes additional parameter which is the buffer length.
diff --git a/localedata/ChangeLog b/localedata/ChangeLog
index 504ba5eb4c..00bf9ea7be 100644
--- a/localedata/ChangeLog
+++ b/localedata/ChangeLog
@@ -1,3 +1,10 @@
+2005-10-14 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #870]
+ * locales/ku_TR: New file.
+ * SUPPORTED (SUPPORTED-LOCALES): Add ku_TR.ISO-8859-9 and
+ ku_TR.UTF-8.
+
2005-10-13 Ulrich Drepper <drepper@redhat.com>
[BZ #533]
diff --git a/localedata/SUPPORTED b/localedata/SUPPORTED
index b9634853fb..d263e91f56 100644
--- a/localedata/SUPPORTED
+++ b/localedata/SUPPORTED
@@ -226,6 +226,8 @@ km_KH/UTF-8 \
kn_IN/UTF-8 \
ko_KR.EUC-KR/EUC-KR \
ko_KR.UTF-8/UTF-8 \
+ku_TR.UTF-8/UTF-8 \
+ku_TR/ISO-8859-9 \
kw_GB.UTF-8/UTF-8 \
kw_GB/ISO-8859-1 \
ky_KG/UTF-8 \
diff --git a/localedata/locales/ku_TR b/localedata/locales/ku_TR
new file mode 100644
index 0000000000..b1486f9b12
--- /dev/null
+++ b/localedata/locales/ku_TR
@@ -0,0 +1,215 @@
+escape_char /
+comment_char %
+
+% Kurdish (latin) language locale for Turkey
+% Source: Kader DILSIZ
+% Contact: Kader DILSIZ, Pablo Saratxaga
+% Email: kader@ikader.com, pablo@mandrakesoft.com
+% Tel:
+% Fax:
+% Language: ku
+% Territory: TR
+% Revision: 0.1
+% Date: 2003-07-27
+% Users: general
+% Charset: UTF-8
+% Distribution and use is free, also
+% for commercial purposes.
+% History:
+
+LC_IDENTIFICATION
+title "Kurdish (latin) locale for Turkey"
+source "Kader DILSIZ"
+address ""
+contact "Kader DILSIZ, Pablo Saratxaga"
+email "kader@ikader.com, pablo@mandrakesoft.com"
+tel ""
+fax ""
+language "Kurdish"
+territory "Turkey"
+revision "0.1"
+date "2003-07-27"
+%
+category "ku_TR:2000";LC_IDENTIFICATION
+category "ku_TR:2000";LC_CTYPE
+category "ku_TR:2000";LC_COLLATE
+category "ku_TR:2000";LC_TIME
+category "ku_TR:2000";LC_NUMERIC
+category "ku_TR:2000";LC_MONETARY
+category "ku_TR:2000";LC_MESSAGES
+category "ku_TR:2000";LC_PAPER
+category "ku_TR:2000";LC_NAME
+category "ku_TR:2000";LC_ADDRESS
+category "ku_TR:2000";LC_TELEPHONE
+category "ku_TR:2000";LC_MEASUREMENT
+
+END LC_IDENTIFICATION
+
+LC_CTYPE
+copy "tr_TR"
+END LC_CTYPE
+
+LC_COLLATE
+copy "iso14651_t1"
+
+%% a b c c, d e e> f g h i i> j k l m n o p q r s s, t u u> v w x y z
+
+collating-symbol <c,>
+collating-symbol <e/>>
+collating-symbol <i.>
+collating-symbol <i/>>
+collating-symbol <s,>
+collating-symbol <u/>>
+
+reorder-after <c>
+<c,>
+reorder-after <e>
+<e/>>
+reorder-after <h>
+<i>
+<i.>
+<i/>>
+reorder-after <s>
+<s,>
+reorder-after <u>
+<u/>>
+
+reorder-after <U0063>
+<U00E7> <c,>;<CDI>;<MIN>;IGNORE
+reorder-after <U0043>
+<U00C7> <c,>;<CDI>;<CAP>;IGNORE
+
+reorder-after <U0065>
+<U00EA> <e/>>;<CIR>;<MIN>;IGNORE
+reorder-after <U0045>
+<U00CA> <e/>>;<CIR>;<CAP>;IGNORE
+
+reorder-after <U0068>
+<U0131> <i>;<BAS>;<MIN>;IGNORE
+<U0069> <i.>;<PCT>;<MIN>;IGNORE
+<U00EE> <i/>>;<CIR>;<MIN>;IGNORE
+reorder-after <U0048>
+<U0049> <i>;<BAS>;<CAP>;IGNORE
+<U0130> <i.>;<PCT>;<CAP>;IGNORE
+<U00CE> <i/>>;<CIR>;<CAP>;IGNORE
+
+reorder-after <U0073>
+<U015F> <s,>;<CDI>;<MIN>;IGNORE
+reorder-after <U0053>
+<U015E> <s,>;<CDI>;<CAP>;IGNORE
+
+reorder-after <U0075>
+<U00FB> <u/>>;<CIR>;<MIN>;IGNORE
+reorder-after <U0055>
+<U00DB> <u/>>;<CIR>;<CAP>;IGNORE
+
+reorder-end
+
+END LC_COLLATE
+
+LC_MONETARY
+copy "tr_TR"
+END LC_MONETARY
+
+LC_NUMERIC
+copy "tr_TR"
+END LC_NUMERIC
+
+LC_TIME
+abday "<U0079><U00EA><U006B>";"<U0064><U0075><U0073>";/
+ "<U0073><U00EA><U0073>";"<U00E7><U0061><U0072>";/
+ "<U0070><U00EA><U006E>";"<U00EE><U006E><U00EE>";/
+ "<U0073><U0065><U0070>"
+day "<U0079><U00EA><U006B><U0073><U00EA><U006D>";/
+ "<U0064><U0075><U0073><U00EA><U006D>";/
+ "<U0073><U00EA><U0073><U00EA><U006D>";/
+ "<U00E7><U0061><U0072><U0073><U00EA><U006D>";/
+ "<U0070><U00EA><U006E><U0063><U0073><U00EA><U006D>";/
+ "<U00EE><U006E><U00EE>";/
+ "<U0073><U0065><U0070><U0074>"
+abmon "<U00C7><U0069><U006C>";"<U0053><U0069><U0062>";/
+ "<U0041><U0064><U0061>";"<U004E><U00EE><U0073>";/
+ "<U0047><U0075><U006C>";"<U0048><U0065><U007A>";/
+ "<U0054><U00EE><U0072>";"<U0054><U0065><U0062>";/
+ "<U00CE><U006C><U006F>";"<U0043><U006F><U0074>";/
+ "<U004D><U0069><U006A>";"<U004B><U0061><U006E>"
+mon "<U00C7><U0069><U006C><U0065>";/
+ "<U0053><U0069><U0062><U0061><U0074>";/
+ "<U0041><U0064><U0061><U0072>";/
+ "<U004E><U00EE><U0073><U0061><U006E>";/
+ "<U0047><U0075><U006C><U0061><U006E>";/
+ "<U0048><U0065><U007A><U00EE><U0072><U0061><U006E>";/
+ "<U0054><U00EE><U0072><U006D><U0065><U0068>";/
+ "<U0054><U0065><U0062><U0061><U0078>";/
+ "<U00CE><U006C><U006F><U006E>";/
+ "<U0043><U006F><U0074><U006D><U0065><U0068>";/
+ "<U004D><U0069><U006A><U0064><U0061><U0072>";/
+ "<U004B><U0061><U006E><U00FB><U006E>"
+% format: %A %d %B %Y %T %Z
+d_t_fmt "<U0025><U0041><U0020><U0025><U0064><U0020><U0025><U0042><U0020><U0025><U0059><U0020><U0025><U0054><U0020><U0025><U005A>"
+% format: %d/%m/%Y
+d_fmt "<U0025><U0064><U002F><U0025><U006D><U002F><U0025><U0059>"
+t_fmt "<U0025><U0054>"
+am_pm "";""
+t_fmt_ampm ""
+% format: %A %d %B %Y
+date_fmt "<U0025><U0041><U0020><U0025><U0064><U0020><U0025><U0042><U0020><U0025><U0059>"
+END LC_TIME
+
+LC_MESSAGES
+yesstr "<U0065><U0072><U00EA>"
+nostr "<U006E><U00E2>"
+% eEdDyY
+yesexpr "<U005E><U005B><U0065><U0045><U0064><U0044><U0079><U0059><U005D><U002E><U002A>"
+% nN
+noexpr "<U005E><U005B><U006E><U004E><U005D><U002E><U002A>"
+END LC_MESSAGES
+
+LC_PAPER
+copy "tr_TR"
+END LC_PAPER
+
+LC_TELEPHONE
+copy "tr_TR"
+END LC_TELEPHONE
+
+LC_MEASUREMENT
+copy "tr_TR"
+END LC_MEASUREMENT
+
+LC_NAME
+% format: %d%t%g%t%m%t%f
+name_fmt "<U0025><U0064><U0025><U0074><U0025><U0067><U0025><U0074>/
+<U0025><U006D><U0025><U0074><U0025><U0066>"
+% TODO
+% Sayżn
+name_gen "<U0053><U0061><U0079><U0131><U006E>"
+% "M."
+name_mr "<U004D><U002E>"
+% "Jne"
+name_mrs "<U004A><U006E><U0065>"
+name_ms "<U004A><U006E><U0065>"
+% "Kc,k"
+name_miss "<U004B><U00E7><U006B>"
+END LC_NAME
+
+LC_ADDRESS
+postal_fmt "<U0025><U0066><U0025><U004E><U0025><U0061><U0025><U004E>/
+<U0025><U0064><U0025><U004E><U0025><U0062><U0025><U004E><U0025><U0073>/
+<U0020><U0025><U0068><U0020><U0025><U0065><U0020><U0025><U0072><U0025>/
+<U004E><U0025><U0025><U007A><U0020><U0025><U0054><U0025>/
+<U004E><U0025><U0063><U0025><U004E>"
+% TODO
+country_name "<U0054><U0075><U0072><U006B><U0065><U0079>"
+country_post "TR"
+country_ab2 "TR"
+country_ab3 "TUR"
+country_num 792
+country_isbn 975
+country_car "TR"
+% "kurdi"
+lang_name "<U006B><U0075><U0072><U0064><U0069>"
+lang_ab "ku"
+lang_term "kur"
+lang_lib "kur"
+END LC_ADDRESS
diff --git a/stdlib/Makefile b/stdlib/Makefile
index 9a9ff8bd45..fa65c95121 100644
--- a/stdlib/Makefile
+++ b/stdlib/Makefile
@@ -63,7 +63,8 @@ tests := tst-strtol tst-strtod testmb testrand testsort testdiv \
test-canon test-canon2 tst-strtoll tst-environ \
tst-xpg-basename tst-random tst-random2 tst-bsearch \
tst-limits tst-rand48 bug-strtod tst-setcontext \
- test-a64l tst-qsort tst-system testmb2 bug-strtod2
+ test-a64l tst-qsort tst-system testmb2 bug-strtod2 \
+ tst-ucontext-off
include ../Makeconfig
diff --git a/stdlib/tst-ucontext-off.c b/stdlib/tst-ucontext-off.c
new file mode 100644
index 0000000000..2e97f21aba
--- /dev/null
+++ b/stdlib/tst-ucontext-off.c
@@ -0,0 +1,35 @@
+#include <stddef.h>
+#include <stdio.h>
+#include <sys/ucontext.h>
+
+#include <ucontext_i.h>
+
+static int
+do_test (void)
+{
+ int nerrors = 0;
+ int ntests = 0;
+
+#define TEST(member, val) \
+ do { \
+ if (offsetof (struct ucontext, member) != val) \
+ { \
+ printf ("offsetof(%s) = %zu, %s = %zu\n", \
+ #member, offsetof (struct ucontext, member), \
+ #val, (size_t) val); \
+ ++nerrors; \
+ } \
+ ++ntests; \
+ } while (0)
+
+#ifdef TESTS
+ TESTS
+#endif
+
+ printf ("%d errors in %d tests\n", nerrors, ntests);
+
+ return nerrors != 0;
+}
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
diff --git a/sysdeps/unix/sysv/linux/i386/ucontext_i.h b/sysdeps/unix/sysv/linux/i386/ucontext_i.h
index d6efca41b1..c6319f2391 100644
--- a/sysdeps/unix/sysv/linux/i386/ucontext_i.h
+++ b/sysdeps/unix/sysv/linux/i386/ucontext_i.h
@@ -1,6 +1,6 @@
/* Offsets and other constants needed in the *context() function
implementation.
- Copyright (C) 2001 Free Software Foundation, Inc.
+ Copyright (C) 2001, 2005 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
@@ -39,3 +39,23 @@
#define oFPREGS 96
#define oSIGMASK 108
#define oFPREGSMEM 236
+
+/* Tests run in stdlib/tst-ucontext-off. */
+#define TESTS \
+ TEST (uc_link, oLINK); \
+ TEST (uc_stack.ss_sp, oSS_SP); \
+ TEST (uc_stack.ss_size, oSS_SIZE); \
+ TEST (uc_mcontext.gregs[REG_GS], oGS); \
+ TEST (uc_mcontext.gregs[REG_FS], oFS); \
+ TEST (uc_mcontext.gregs[REG_EDI], oEDI); \
+ TEST (uc_mcontext.gregs[REG_ESI], oESI); \
+ TEST (uc_mcontext.gregs[REG_EBP], oEBP); \
+ TEST (uc_mcontext.gregs[REG_ESP], oESP); \
+ TEST (uc_mcontext.gregs[REG_EBX], oEBX); \
+ TEST (uc_mcontext.gregs[REG_EDX], oEDX); \
+ TEST (uc_mcontext.gregs[REG_ECX], oECX); \
+ TEST (uc_mcontext.gregs[REG_EAX], oEAX); \
+ TEST (uc_mcontext.gregs[REG_EIP], oEIP); \
+ TEST (uc_mcontext.fpregs, oFPREGS); \
+ TEST (uc_sigmask, oSIGMASK); \
+ TEST (__fpregs_mem, oFPREGSMEM);
diff --git a/sysdeps/unix/sysv/linux/x86_64/ucontext_i.h b/sysdeps/unix/sysv/linux/x86_64/ucontext_i.h
index 5451a308ee..e5099084cf 100644
--- a/sysdeps/unix/sysv/linux/x86_64/ucontext_i.h
+++ b/sysdeps/unix/sysv/linux/x86_64/ucontext_i.h
@@ -1,6 +1,6 @@
/* Offsets and other constants needed in the *context() function
implementation for Linux/x86-64.
- Copyright (C) 2002 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2005 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
@@ -41,7 +41,29 @@
#define oRAX 144
#define oRCX 152
#define oRIP 168
-#define oFPREGS 208
-#define oSIGMASK 280
-#define oFPREGSMEM 408
-#define oMXCSR 432
+#define oFPREGS 224
+#define oSIGMASK 296
+#define oFPREGSMEM 424
+#define oMXCSR 448
+
+/* Tests run in stdlib/tst-ucontext-off. */
+#define TESTS \
+ TEST (uc_mcontext.gregs[REG_RBP], oRBP); \
+ TEST (uc_mcontext.gregs[REG_RSP], oRSP); \
+ TEST (uc_mcontext.gregs[REG_RBX], oRBX); \
+ TEST (uc_mcontext.gregs[REG_R8], oR8); \
+ TEST (uc_mcontext.gregs[REG_R9], oR9); \
+ TEST (uc_mcontext.gregs[REG_R12], oR12); \
+ TEST (uc_mcontext.gregs[REG_R13], oR13); \
+ TEST (uc_mcontext.gregs[REG_R14], oR14); \
+ TEST (uc_mcontext.gregs[REG_R15], oR15); \
+ TEST (uc_mcontext.gregs[REG_RDI], oRDI); \
+ TEST (uc_mcontext.gregs[REG_RSI], oRSI); \
+ TEST (uc_mcontext.gregs[REG_RDX], oRDX); \
+ TEST (uc_mcontext.gregs[REG_RAX], oRAX); \
+ TEST (uc_mcontext.gregs[REG_RCX], oRCX); \
+ TEST (uc_mcontext.gregs[REG_RIP], oRIP); \
+ TEST (uc_mcontext.fpregs, oFPREGS); \
+ TEST (uc_sigmask, oSIGMASK); \
+ TEST (__fpregs_mem, oFPREGSMEM); \
+ TEST (__fpregs_mem.mxcsr, oMXCSR);
diff --git a/time/bug-asctime_r.c b/time/bug-asctime_r.c
index 2579a6a3b0..86651ef1c5 100644
--- a/time/bug-asctime_r.c
+++ b/time/bug-asctime_r.c
@@ -13,12 +13,18 @@ do_test (void)
tp->tm_year = 10000 - 1900;
char buf[1000];
errno = 0;
+ buf[26] = '\xff';
char *s = asctime_r (tp, buf);
if (s != NULL || errno != EOVERFLOW)
{
puts ("asctime_r did not fail correctly");
result = 1;
}
+ if (buf[26] != '\xff')
+ {
+ puts ("asctime_r overwrote 27th byte in buffer");
+ result = 1;
+ }
return result;
}