public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX
@ 2010-04-08 11:39 suzuki at in dot ibm dot com
2010-04-08 11:49 ` [Bug libc/11478] " schwab at linux-m68k dot org
` (4 more replies)
0 siblings, 5 replies; 7+ messages in thread
From: suzuki at in dot ibm dot com @ 2010-04-08 11:39 UTC (permalink / raw)
To: glibc-bugs
The __tzset_parse_tz fails to parse the valid string formats as described by POSIX.
This was introduced with the following commit.
http://sourceware.org/git/?p=glibc.git;a=commit;h=82780cbee540bc7e61de6eb165d0f3ec7aa9e549
$ cat tzset-minimal.c
#include <time.h>
extern char* tzname[];
main()
{
tzset();
printf ("std tzname is %s\n", *tzname[0]?tzname[0]:"NULL");
return 0;
}
$ TZ="A?BC0" ./tzset-minimal
std tzname is NULL
--
Summary: __tzset_parse_tz doesn't conform to POSIX
Product: glibc
Version: 2.9
Status: NEW
Severity: normal
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: suzuki at in dot ibm dot com
CC: glibc-bugs at sources dot redhat dot com
GCC build triplet: all
GCC host triplet: all
GCC target triplet: all
http://sourceware.org/bugzilla/show_bug.cgi?id=11478
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug libc/11478] __tzset_parse_tz doesn't conform to POSIX
2010-04-08 11:39 [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX suzuki at in dot ibm dot com
@ 2010-04-08 11:49 ` schwab at linux-m68k dot org
2010-04-08 11:59 ` suzuki at in dot ibm dot com
` (3 subsequent siblings)
4 siblings, 0 replies; 7+ messages in thread
From: schwab at linux-m68k dot org @ 2010-04-08 11:49 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From schwab at linux-m68k dot org 2010-04-08 11:49 -------
POSIX does not specify the interpretation of this time zone string.
--
http://sourceware.org/bugzilla/show_bug.cgi?id=11478
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug libc/11478] __tzset_parse_tz doesn't conform to POSIX
2010-04-08 11:39 [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX suzuki at in dot ibm dot com
2010-04-08 11:49 ` [Bug libc/11478] " schwab at linux-m68k dot org
@ 2010-04-08 11:59 ` suzuki at in dot ibm dot com
2010-04-08 12:03 ` suzuki at in dot ibm dot com
` (2 subsequent siblings)
4 siblings, 0 replies; 7+ messages in thread
From: suzuki at in dot ibm dot com @ 2010-04-08 11:59 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From suzuki at in dot ibm dot com 2010-04-08 11:59 -------
http://www.opengroup.org/onlinepubs/007908775/xbd/envvar.html
--
http://sourceware.org/bugzilla/show_bug.cgi?id=11478
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug libc/11478] __tzset_parse_tz doesn't conform to POSIX
2010-04-08 11:39 [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX suzuki at in dot ibm dot com
2010-04-08 11:49 ` [Bug libc/11478] " schwab at linux-m68k dot org
2010-04-08 11:59 ` suzuki at in dot ibm dot com
@ 2010-04-08 12:03 ` suzuki at in dot ibm dot com
2010-04-08 12:12 ` drepper at redhat dot com
2010-04-08 12:42 ` suzuki at in dot ibm dot com
4 siblings, 0 replies; 7+ messages in thread
From: suzuki at in dot ibm dot com @ 2010-04-08 12:03 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From suzuki at in dot ibm dot com 2010-04-08 12:02 -------
The tzset() page points to the page for environment variables.
http://www.opengroup.org/onlinepubs/007908775/xsh/tzset.html ->
http://www.opengroup.org/onlinepubs/007908775/xbd/envvar.html
--
http://sourceware.org/bugzilla/show_bug.cgi?id=11478
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug libc/11478] __tzset_parse_tz doesn't conform to POSIX
2010-04-08 11:39 [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX suzuki at in dot ibm dot com
` (2 preceding siblings ...)
2010-04-08 12:03 ` suzuki at in dot ibm dot com
@ 2010-04-08 12:12 ` drepper at redhat dot com
2010-04-08 12:42 ` suzuki at in dot ibm dot com
4 siblings, 0 replies; 7+ messages in thread
From: drepper at redhat dot com @ 2010-04-08 12:12 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From drepper at redhat dot com 2010-04-08 12:12 -------
(In reply to comment #3)
> The tzset() page points to the page for environment variables.
>
> http://www.opengroup.org/onlinepubs/007908775/xsh/tzset.html ->
>
> http://www.opengroup.org/onlinepubs/007908775/xbd/envvar.html
And? The format is specified as
std offset dst offset, rule
where std is either
<[a-zA-Z0-9+-]{3,TZNAME_MAX}>
or
[a-zA-Z]{3,TZNAME_MAX}
Nowhere a question mark is allowed. That form is just invalid and the
implementation is correct to reject it.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |INVALID
http://sourceware.org/bugzilla/show_bug.cgi?id=11478
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug libc/11478] __tzset_parse_tz doesn't conform to POSIX
2010-04-08 11:39 [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX suzuki at in dot ibm dot com
` (3 preceding siblings ...)
2010-04-08 12:12 ` drepper at redhat dot com
@ 2010-04-08 12:42 ` suzuki at in dot ibm dot com
4 siblings, 0 replies; 7+ messages in thread
From: suzuki at in dot ibm dot com @ 2010-04-08 12:42 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From suzuki at in dot ibm dot com 2010-04-08 12:42 -------
You are right. POSIX doesn't say it can be any character. It clearly says it
should be alphanumeric in < > or alphabetic. It is the SUSv3 which says it can
be any character.
[ snip ]
Where:
std and dst
Indicates no less than three, nor more than {TZNAME_MAX}, bytes that are the
designation for the standard ( std ) or the alternative ( dst - such as Daylight
Savings Time) timezone. Only std is required; if dst is missing, then the
alternative time does not apply in this locale. Upper- and lower-case letters
are explicitly allowed. Any graphic characters except a leading colon (:) or
digits, the comma (,), the minus (-), the plus (+), and the null character are
permitted to appear in these fields, but their meaning is unspecified.
--
http://sourceware.org/bugzilla/show_bug.cgi?id=11478
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 7+ messages in thread
[parent not found: <bug-11478-131@http.sourceware.org/bugzilla/>]
end of thread, other threads:[~2014-06-30 18:18 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-08 11:39 [Bug libc/11478] New: __tzset_parse_tz doesn't conform to POSIX suzuki at in dot ibm dot com
2010-04-08 11:49 ` [Bug libc/11478] " schwab at linux-m68k dot org
2010-04-08 11:59 ` suzuki at in dot ibm dot com
2010-04-08 12:03 ` suzuki at in dot ibm dot com
2010-04-08 12:12 ` drepper at redhat dot com
2010-04-08 12:42 ` suzuki at in dot ibm dot com
[not found] <bug-11478-131@http.sourceware.org/bugzilla/>
2014-06-30 18:18 ` fweimer at redhat dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).