This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: CVS HEAD broken for x86_64-pc-mingw32
- From: Kai Tietz <Kai dot Tietz at onevision dot com>
- To: Nick Clifton <nickc at redhat dot com>
- Cc: Binutils <binutils at sourceware dot org>, NightStrike <nightstrike at gmail dot com>
- Date: Fri, 11 Apr 2008 09:52:40 +0200
- Subject: Re: CVS HEAD broken for x86_64-pc-mingw32
Hi Nick,
Nick Clifton <nickc@redhat.com> wrote on 11.04.2008 09:34:54:
> >> ../../src/gas/listing.c:1072: error: implicit declaration of function
> >> 'localtime_r'
>
> > But for backward compatibility issue may this call should be modified
to
> > use localtime()
>
> Could you guys just confirm for me that the attached patch will solve
> the problem before I check it in ? Thanks.
The patch is ok and solve the problem AFAICS.
Cheers,
Kai
| (\_/) This is Bunny. Copy and paste Bunny
| (='.'=) into your signature to help him gain
| (")_(") world domination.
> Index: gas/listing.c
> ===================================================================
> RCS file: /cvs/src/src/gas/listing.c,v
> retrieving revision 1.33
> diff -c -3 -p -r1.33 listing.c
> *** gas/listing.c 10 Apr 2008 12:45:17 -0000 1.33
> --- gas/listing.c 11 Apr 2008 07:33:17 -0000
> *************** static void
> *** 1065,1076 ****
> print_timestamp (void)
> {
> const time_t now = time (NULL);
> ! struct tm timestamp;
> char stampstr[MAX_DATELEN];
>
> /* Any portable way to obtain subsecond values??? */
> ! localtime_r (&now, ×tamp);
> ! strftime (stampstr, MAX_DATELEN, "%Y-%m-%dT%H:%M:%S.000%z",
×tamp);
> fprintf (list_file, _("\n time stamp \t: %s\n\n"), stampstr);
> }
>
> --- 1065,1076 ----
> print_timestamp (void)
> {
> const time_t now = time (NULL);
> ! struct tm * timestamp;
> char stampstr[MAX_DATELEN];
>
> /* Any portable way to obtain subsecond values??? */
> ! timestamp = localtime (&now);
> ! strftime (stampstr, MAX_DATELEN, "%Y-%m-%dT%H:%M:%S.000%z",
timestamp);
> fprintf (list_file, _("\n time stamp \t: %s\n\n"), stampstr);
> }
>