bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs current-time-string core dump on 64-bit hosts


From: Kevin Rodgers
Subject: Re: Emacs current-time-string core dump on 64-bit hosts
Date: Fri, 17 Mar 2006 09:04:40 -0700
User-agent: Mozilla Thunderbird 0.9 (X11/20041105)

Eli Zaretskii wrote:
From: Paul Eggert <eggert@CS.UCLA.EDU>
Gcc: nnfolder+archive:outgo
Date: Thu, 16 Mar 2006 21:58:09 -0800

2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>

        Do not use ctime, since it has undefined behavior with
        out-of-range time stamps.  This fixes a bug where
        (current-time-string '(2814749767106 0)) would make Emacs dump
        core on 64-bit Solaris 8; the fix is to remove all uses of ctime
        from the Emacs source code.


Personally, I find it preposterous that we need to reinvent library
functions.  Isn't there a better (safer) library function, or a
combination thereof, that we could use instead of rolling our own?

Why not have Emacs test for an out-of-range time stamp before
calling ctime?

--
Kevin Rodgers





reply via email to

[Prev in Thread] Current Thread [Next in Thread]