WANTED: C routine to return current date/time

WANTED: C routine to return current date/time

Post by Alan McK » Fri, 17 Nov 1995 04:00:00



I want a simple C routine that will return a string containing the
current date and time.  Sure, I could write it myself, but if someone
already has one, so much the better.

Must run on Solaris 2.3 and 2.4.

Please reply via email

thanks,
-Alan

--
               Why isn't "phonetic" spelled the way it sounds?
http://www.acadiau.ca/cc/alan/

 
 
 

WANTED: C routine to return current date/time

Post by Tony Curt » Fri, 17 Nov 1995 04:00:00


Alan> I want a simple C routine that will return a string
Alan> containing the current date and time.  Sure, I could
Alan> write it myself, but if someone already has one, so
Alan> much the better.

% man -k date
ctime, asctime, dysize, gmtime, localtime, strftime,
    strptime, timegm, timelocal,
                 tzset, tzsetwall (3V) - convert date and time

(line broken for news posting)
hope that helps
tony

 
 
 

1. date/time of a file compare with current date/time

Hi,

I hope i can drop my question about Linux shell programming here?

I'm writing a script in bash to find files. I'm using the slocate
programm, which is being runned every hour using a cron job, to create
it's database.

Now i want to know how long it is ago that the database has been
recreated. Zo i need to check the date and time from that file and
compare it with the current date and time. I know there must be easy to
do but i can't find the trick to do it.

Maikel van Gorkom

Sent via Deja.com http://www.deja.com/
Before you buy.

2. Emacs problem

3. DATE / TIME with f2c (Was: Re: Timing Routines)

4. How can lock user???

5. run time date and syslog date/time conflict

6. wireless pci network card problem

7. current date & time from Fortran

8. Linux Portable Device

9. question obtain the current date and time on a UNIX system.

10. Getting current date and time.

11. AIX returns bad current-time-string

12. How to Compare File Date to Current Date

13. Wanted: xftp that preserves file dates/times?