_strdate should return maximum 8 chars

does not work yet

svn path=/trunk/; revision=22204
This commit is contained in:
Johannes Anderwald 2006-06-04 13:20:09 +00:00
parent 8d494b3a7b
commit 36c9262fd0
2 changed files with 3 additions and 2 deletions

View file

@ -24,6 +24,7 @@ char* _strdate(char* datestr)
}
t = time(NULL);
d = localtime(&t);
sprintf(dt,"%d/%d/%d",d->tm_mday,d->tm_mon+1,d->tm_year);
sprintf(dt,"%.2d/%.2d/%.2d",d->tm_mday,d->tm_mon+1,d->tm_year );
return dt;
}

View file

@ -24,6 +24,6 @@ wchar_t* _wstrdate(wchar_t* datestr)
}
t = time(NULL);
d = localtime(&t);
swprintf(dt,L"%d/%d/%d",d->tm_mday,d->tm_mon+1,d->tm_year);
swprintf(dt,L"%.2d/%.2d/%.2d",d->tm_mday,d->tm_mon+1,d->tm_year);
return dt;
}