mirror of
https://github.com/samba-team/samba.git
synced 2025-01-27 14:04:05 +03:00
Fix from NAKAJI Hiroyuki for a trailing '\n\ in asctime.
Jeremy. (This used to be commit 87df97c9365a185e4ea6bac7b832b8cf38144624)
This commit is contained in:
parent
08607c3e0c
commit
321091ad20
@ -495,6 +495,8 @@ char *http_timestring(time_t t)
|
|||||||
else
|
else
|
||||||
#ifndef HAVE_STRFTIME
|
#ifndef HAVE_STRFTIME
|
||||||
fstrcpy(buf, asctime(tm));
|
fstrcpy(buf, asctime(tm));
|
||||||
|
if(buf[strlen(buf)-1] == '\n')
|
||||||
|
buf[strlen(buf)-1] = 0;
|
||||||
#else /* !HAVE_STRFTIME */
|
#else /* !HAVE_STRFTIME */
|
||||||
strftime(buf, sizeof(buf)-1, "%a, %d %b %Y %H:%M:%S %Z", tm);
|
strftime(buf, sizeof(buf)-1, "%a, %d %b %Y %H:%M:%S %Z", tm);
|
||||||
#endif /* !HAVE_STRFTIME */
|
#endif /* !HAVE_STRFTIME */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user