delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2014/03/05/09:06:21

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:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; q=dns; s=
default; b=j1lUfHhGa7XGRvaqtd1Rue4X7lEHQjzhG5iWTusjRXm7Mw2bo9J3C
/sauNrm0U6y1B7yqLYqNU+0QlQW1f/xbd+AVYiLqzWZVvkBs/ywVEvMHGpx3KiRy
nQifkQ9uoSQvNrVEzwOzJbf1SAdXtEYqJoSoBM39Uiiz8Yij8ymXZ4=
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:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; s=default;
bh=+4JEzBzcgE/wY4ez/QpzWf80BrY=; b=XVIpfe5MibLe75vgieLPz1SCz8+M
ODMPEj32BphZA7Cmxy7ADzzjfWuJLSSXfN98i+PueISS52CW440SLdvW1wKJ/H6k
tfsa0CX32rhqu3IHOTqnloEuP3T6hOlT8yVo35g4zLb0sOtVFAwHjEbpgJCrq66w
rLUL/pVO58PgzD4=
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=-4.9 required=5.0 tests=AWL,BAYES_00,UNSUBSCRIBE_BODY autolearn=no version=3.3.2
X-HELO: calimero.vinschen.de
Date: Wed, 5 Mar 2014 15:05:53 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: struct tm problem
Message-ID: <20140305140553.GC2192@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <CAJoYywWqyBYEJKriugeU0deHm=DsS_LYgHotaX6K=q6TO_tmQQ AT mail DOT gmail DOT com> <20140304081928 DOT GF7236 AT calimero DOT vinschen DOT de> <CAJoYywUF2gpX5+-9H3gExyRMYUtJQyi_mHOX42uG9kRfaQ0Nvg AT mail DOT gmail DOT com> <53172C18 DOT 5090906 AT redhat DOT com>
MIME-Version: 1.0
In-Reply-To: <53172C18.5090906@redhat.com>
User-Agent: Mutt/1.5.21 (2010-09-15)

--nmemrqcdn5VTmUEE
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mar  5 06:52, Eric Blake wrote:
> On 03/05/2014 03:45 AM, Irfan Adilovic wrote:
> > If it is recognized that the executable was compiled against a
> > different sized struct tm, how would you instruct cygwin1.dll code not
> > to write to tm_gmtoff?
>=20
> Linker magic, the same as how we converted to 64-bit stat, and the same
> as what we will eventually have to do if we want to convert to 64-bit
> time_t.  Basically, we add a new entry point, and alias the public name
> to the new entry point.  Any old program is still linked to the old
> name, where we know they use the smaller size.  Any new program is
> linked to the new name, where we know they use the larger size.  New
> programs cannot run against the old dll, but the new dll is able to
> handle both old and new apps by virtue of dual entry points.

Not in this case.  I just applied a patch which simply tests the API
version of the executable and skips the code handling tm_offset and
tm_zone, which are just a few lines anyway.

What you describe above is what we would have to do if we change
sizeof(time_t) from 4 to 8 on 32 bit, which is something I won't have on
my plate any time soon.  I'm quite satisfied that the 64 bit version has
a 8 byte time_t.  Not that I wouldn't appreciate patches...


Corinna



--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--nmemrqcdn5VTmUEE
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBAgAGBQJTFy9BAAoJEPU2Bp2uRE+g6dgQAIZFUBXyzaDu6A6TxZN91vDR
9M5d2FXsPt+Zt6bkPTx/g1G/9wm751KRVnnYc4sFOEWHjtNR1tFdMWzGtX1csLnC
7pXp40gw/JdW8rZE49GyB2Dtxhztr2C+uXLFHI9VP8eg3KBnEvy6erf9ppIwBzLE
jMlbf58J6TMYFnm4nmbrKN/nFgNMGSVteSg1MJQaGcQa3NNv+F236AzpAhLYKLvH
ec/s0Cx87joeFWgSFFt5mcuT6F3CHzw3CMxOTsA0dCpXNfd20lTUAZPQ1WLnXzet
NdVJkpe0kE0y+pdtmybh6hbXPsz8ylabDtL/vADPJp/5vCsYR9pl0yBpM7k1fR8C
lWSu+mHN8b0y8/gvLlklHI0Os4mN12dvMS8Og6UJp4KXX6n+bSbh70K/xZ7xE0wx
aHf8Yqtx6hLECSdgkz3VVc+GJ2BucCHEK3geGYPPyzi4HiH1A67IeBVMkbok4Ukg
VxFaSG2WR8ykxG/xmgUSCuRJcWqOOR02DESVHnM49pv/9vv8Jn5Nz60idavhfTon
fbJYvvc6rlbp8vidTKTM6iVMi4PWKt313LBx9qeOLyRtgTqtsP/WQEt0dsjobtnL
QtYuGKfSXUdTCwIypV2TJR7uHyQv2HO+1cgEJFOFMmQx0pe3+u3n2nIT+g9k3L9k
dKlnPFUhoRU1KYP4fILL
=Ulwi
-----END PGP SIGNATURE-----

--nmemrqcdn5VTmUEE--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019