From: Marc Roussel <roussel@henri.chem.uleth.ca>
Subject: Re: Problem with C compiler?
Date: 1996/08/30 [thread overview]
Message-ID: <3226FF31.41C6@henri.chem.uleth.ca> (raw)
In-Reply-To: 28AUG96.13550198.0011@AACCI.AACC.CC.MD.US
Scott Kramer wrote:
> I keep getting a segmentation fault when using the time()
> function. I have looked at the cc documentation over and over and
> can see no reason why this will not work.
>
> long *tloc;
> time(tloc);
Your code is nonportable. Read the time(3) man page. tloc should be
pointer-to-time_t and time_t is defined in time.h. As it happens,
time_t is not a long but an int on the alpha.
Marc R. Roussel
(roussel@henri.chem.uleth.ca)
Department of Chemistry
University of Lethbridge
prev parent reply other threads:[~1996-08-30 4:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-08-28 4:00 Problem with C compiler? Scott Kramer
1996-08-29 4:00 ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
1996-08-29 4:00 ` Tim Mooney
1996-08-30 4:00 ` Marc Roussel [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox