diff options
author | Tim Potter <tpot@samba.org> | 2003-11-04 20:09:44 +0000 |
---|---|---|
committer | Tim Potter <tpot@samba.org> | 2003-11-04 20:09:44 +0000 |
commit | 761e13da4ef8294f0b131ad7f672d023b0d222f6 (patch) | |
tree | 972e13a92edf289f49bd1c62e59214e2f4338398 /source | |
parent | 66e5043553939be2b124bec8581f08b01fdf9c1e (diff) | |
download | samba-761e13da4ef8294f0b131ad7f672d023b0d222f6.tar.gz samba-761e13da4ef8294f0b131ad7f672d023b0d222f6.tar.xz samba-761e13da4ef8294f0b131ad7f672d023b0d222f6.zip |
Use the actual size of the buffer in strftime instead of a made up value
which just happens to be less than sizeof(fstring). Closes #713.
Diffstat (limited to 'source')
-rw-r--r-- | source/lib/time.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/lib/time.c b/source/lib/time.c index 74ca56bdc5c..635ede9be22 100644 --- a/source/lib/time.c +++ b/source/lib/time.c @@ -694,7 +694,7 @@ char *timestring(BOOL hires) ".%06ld", (long)tp.tv_usec); } else { - strftime(TimeBuf,100,"%Y/%m/%d %H:%M:%S",tm); + strftime(TimeBuf,sizeof(TimeBuf)-1,"%Y/%m/%d %H:%M:%S",tm); } #else if (hires) { |