([NSDate -description]): replace strftime() with sprintf() equivalent

for NEXTSTEP.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@730 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Andrew McCallum 1996-01-16 00:48:44 +00:00
parent 75110caa2e
commit 9dacb328cb

View file

@ -212,7 +212,11 @@
Date: Fri, 12 Jan 96 16:00:42 +0100
*/
#ifdef NeXT
buf[0] = '\0';
sprintf(buf,"%4d-%02d-%02d %02d:%02d:%02d %c%02d%02d",
1900+theTime->tm_year, theTime->tm_mon+1, theTime->tm_mday,
theTime->tm_hour, theTime->tm_min, theTime->tm_sec,
(theTime->tm_gmtoff>0)?'+':'-', abs(theTime->tm_gmtoff)/3600,
(abs(theTime->tm_gmtoff)/60)%60);
#else
strftime(buf, 64, "%Y-%m-%d %H:%M:%S", theTime);
#endif