svn commit: r208110 - head/usr.sbin/fifolog/lib
Poul-Henning Kamp
phk at FreeBSD.org
Sat May 15 08:57:17 UTC 2010
Author: phk
Date: Sat May 15 08:57:16 2010
New Revision: 208110
URL: http://svn.freebsd.org/changeset/base/208110
Log:
Do not attempt to render a logrecord with length byte, until we have
decompressed all the bytes required.
Modified:
head/usr.sbin/fifolog/lib/fifolog_reader.c
Modified: head/usr.sbin/fifolog/lib/fifolog_reader.c
==============================================================================
--- head/usr.sbin/fifolog/lib/fifolog_reader.c Sat May 15 07:07:38 2010 (r208109)
+++ head/usr.sbin/fifolog/lib/fifolog_reader.c Sat May 15 08:57:16 2010 (r208110)
@@ -225,6 +225,8 @@ fifolog_reader_chop(struct fifolog_reade
if (u & FIFOLOG_LENGTH) {
v = p[w];
w++;
+ if (p + w + v >= q)
+ return (p);
} else {
for (v = 0; p + v + w < q && p[v + w] != '\0'; v++)
continue;
More information about the svn-src-all
mailing list