summaryrefslogtreecommitdiff
path: root/lib/getdate.y
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1994-10-08 00:40:55 +0000
committerJim Meyering <jim@meyering.net>1994-10-08 00:40:55 +0000
commitd734172c73f2bf1e850e896a615f7d6f1dbf4445 (patch)
treeccd6e3216931c8d4717188e252f2de3c515b3c8d /lib/getdate.y
parent5a31cea3d4d2f9293fdb794b950952ae89753883 (diff)
downloadcoreutils-d734172c73f2bf1e850e896a615f7d6f1dbf4445.tar.xz
merge with 1.10q
Diffstat (limited to 'lib/getdate.y')
-rw-r--r--lib/getdate.y6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/getdate.y b/lib/getdate.y
index e77cc1f62..77d63a9e9 100644
--- a/lib/getdate.y
+++ b/lib/getdate.y
@@ -962,11 +962,13 @@ main (ac, av)
int ac;
char *av[];
{
- char buff[128];
- time_t d;
+ char buff[MAX_BUFF_LEN + 1];
+ time_t d;
(void)printf ("Enter date, or blank line to exit.\n\t> ");
(void)fflush (stdout);
+
+ buff[MAX_BUFF_LEN] = 0;
while (fgets (buff, MAX_BUFF_LEN, stdin) && buff[0]) {
d = get_date (buff, (struct timeb *)NULL);
if (d == -1)