delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
DomainKey-Signature: | a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:date:message-id:from:to:subject:in-reply-to | |
:references:mime-version:content-type:content-transfer-encoding; | |
q=dns; s=default; b=iCb99mMOdvriNchA2iqbj+g579yuFXGejlmljssnsKW | |
prj6d2fJgfUZzoyOM2Ep0R4aYLBk93oqXK/MaaqU9tQlpG2iB0cBlxClDPZcN8py | |
P4qW0EjZiX3zzAXPKepzRULSE4drZ88lRHDnheTeHOtqBriIsszSmW9I3CMbmCGs | |
= | |
DKIM-Signature: | v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:date:message-id:from:to:subject:in-reply-to | |
:references:mime-version:content-type:content-transfer-encoding; | |
s=default; bh=VLNmbe/YoPfoelvk/iVzHQXy/CU=; b=XHttirYPm4FQG70XJ | |
li4py5ij3uPEZDAUtcgorVkodvtlRbWg+q64LcdleOrdQt5B5CvsyWkgSnzgy0sl | |
SuKY+wna2euORFBCDZnaw++CpVBKYALAoqNMREdlTC0ErEba2dy0uN2tRoHulqkZ | |
G1BUb/7wJlWVaIbM4d1QpJYX8Q= | |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
Authentication-Results: | sourceware.org; auth=none |
X-Virus-Found: | No |
X-Spam-SWARE-Status: | No, score=-3.3 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy=H*i:sk:2eddaaf, H*MI:sk:2eddaaf, H*f:sk:2eddaaf, Hx-languages-length:1639 |
X-HELO: | mgwym04.jp.fujitsu.com |
X-SecurityPolicyCheck: | OK by SHieldMailChecker v2.2.3 |
X-SHieldMailCheckerPolicyVersion: | FJ-ISEC-20140219-2 |
Date: | Thu, 26 May 2016 15:54:00 +0900 |
Message-ID: | <o8xh9dltilz.wl-koba@jp.fujitsu.com> |
From: | KOBAYASHI Shinji <koba AT jp DOT fujitsu DOT com> |
To: | cygwin AT cygwin DOT com |
Subject: | Re: Invalid tm_zone from localtime() when TZ is not set |
In-Reply-To: | <2eddaaf6-4e37-cd9b-aa9d-8a87234d0cf9@t-online.de> <20160525084430.GA17601@calimero.vinschen.de> |
References: | <o8xeg8x7e2r DOT wl-koba AT jp DOT fujitsu DOT com> <932D033F-9DA4-4901-9158-328AA929FEC8 AT etr-usa DOT com> <o8x8tz573zs DOT wl-koba AT jp DOT fujitsu DOT com> <CAEhDDbA-ATpAtVggR7cfqn58AHw0sPK_Y3mNSJ8UO29sg2ZpuA AT mail DOT gmail DOT com> <o8x37pd6nlm DOT wl-koba AT jp DOT fujitsu DOT com> <o8xposa6fcl DOT wl-koba AT jp DOT fujitsu DOT com> <20160525084430 DOT GA17601 AT calimero DOT vinschen DOT de> <2eddaaf6-4e37-cd9b-aa9d-8a87234d0cf9 AT t-online DOT de> |
User-Agent: | Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (=?ISO-8859-4?Q?Goj=F2?=) APEL/10.8 EasyPG/1.0.0 Emacs/24.5 (x86_64-unknown-cygwin) MULE/6.0 (HANACHIRUSATO) |
MIME-Version: | 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") |
X-TM-AS-MML: | disable |
X-IsSubscribed: | yes |
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id u4Q6sfMP004587 |
On Wed, 25 May 2016 22:02:50 +0200, Hans-Bernhard Bröker wrote: > On May 25 11:28, KOBAYASHI Shinji wrote: >> The intention of the following code in tzsetwall() should be to pick >> up UPPERCASE letters "in ASCII range": > Are you sure you're not mixing ASCII with '8-bit character' range there? I'm not sure if non-ASCII 8-bit characters are allowed as TZ names. I just guessed the intention from the fact isupper() is used, and from the description of isupper() man page: - isupper is a macro which classifies ASCII integer values by table lookup. - It is defined only when isascii(c) is true or c is EOF. However, the implementation of isupper() seems to work for 8-bit characters even if isascii() is false. Does the man page need some changes? > A proper solution may have to be more like this: > int mapped = wctob(*src); > /* this call is safe now because of how wctob() works: */ > if (isupper(mapped)) { > *dst++ = (unsigned char)mapped; > } Thank you for pointing out wctob(). I'm in favor of fixing this way. On Wed, 25 May 2016 10:44:30 +0200, Corinna Vinschen wrote: > However, testing this with GLibc it turns out that GLibc's towlower does not > transform the character but returns 0xff21. Can anybody explain to me why? It seems that it depends on locale. The man page (on Linux) says: The behavior of towlower() depends on the LC_CTYPE category of the current locale. I observed that it returns 0xff41 when LANG=ja_JP.UTF-8, and 0xff21 when LANG=C. Cygwin's implementation (and man page) does not seem to depend on locale. Regards, KOBAYASHI Shinji. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |