delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/07/24/17:31:11

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <3B5DE7EC.6D450536@iee.org>
Date: Tue, 24 Jul 2001 22:26:04 +0100
From: Don Sharp <dwsharp AT iee DOT org>
X-Mailer: Mozilla 4.74 [en] (WinNT; U)
X-Accept-Language: en
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: 1.3.2 bug on NT 4: localtime() & timestring() set errno on success
References: <OFD7CC7B3F DOT 9278EDCD-ON88256A93 DOT 0065D821 AT rsc DOT raytheon DOT com> <20010724223108 DOT A4550 AT ping DOT be>


Kurt Roeckx wrote:
> 
> On Tue, Jul 24, 2001 at 11:41:26AM -0700, Larisa A Stephan wrote:
> > I notice that localtime() and timestring() tend to set errno to 0x2 even
> > though they succeed (return a non-NULL pointer).  I THINK this is a bug,
> > but maybe someone can correct me.  I checked the archives and found one
> > mention of this issue, but no one followed up to tell the guy he was nuts,
> > so maybe it is really a bug.
> 
> They themself are no system calls, but probably do call system
> calls.  Any of the system calls it might have called could have
> change errno.

In days of yore, it was unsafe to examine errno's value unless an error
had been indicated. As Kurt says above, any system call can alter errno.

Cheers

Don Sharp

> 
> My guess is that it's trying to open some file, but didn't find
> it.
> 
> Kurt
> 
> --
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Bug reporting:         http://cygwin.com/bugs.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


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