diff options
| author | svn2git <svn2git@FreeBSD.org> | 1994-05-01 08:00:00 +0000 |
|---|---|---|
| committer | svn2git <svn2git@FreeBSD.org> | 1994-05-01 08:00:00 +0000 |
| commit | a16f65c7d117419bd266c28a1901ef129a337569 (patch) | |
| tree | 2626602f66dc3551e7a7c7bc9ad763c3bc7ab40a /usr.bin/join | |
| parent | 8503f4f13f77abf7adc8f7e329c6f9c1d52b6a20 (diff) | |
Release FreeBSD 1.1upstream/1.1.0_cvsrelease/1.1.0_cvs
This commit was manufactured to restore the state of the 1.1-RELEASE image.
Releases prior to 5.3-RELEASE are omitting the secure/ and crypto/ subdirs.
Diffstat (limited to 'usr.bin/join')
| -rw-r--r-- | usr.bin/join/join.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/join/join.c b/usr.bin/join/join.c index 14bbc4cd1a25..bfe526f67889 100644 --- a/usr.bin/join/join.c +++ b/usr.bin/join/join.c @@ -309,16 +309,16 @@ slurp(F) } if ((bp = fgetline(F->fp, &len)) == NULL) return; - if (lp->linealloc <= len) { + while (lp->linealloc <= len) { lp->linealloc += 100; if ((lp->line = realloc(lp->line, lp->linealloc * sizeof(char))) == NULL) enomem(); } - bcopy(bp, lp->line, len); + bcopy(bp, lp->line, len+1); /* Split the line into fields, allocate space as necessary. */ - token = bp; + token = lp->line; lp->fieldcnt = 0; while ((fieldp = strsep(&token, tabchar)) != NULL) { if (spans && *fieldp == '\0') |
