Author: kensmith
Date: Mon May 24 15:26:40 2010
New Revision: 208506
URL: http://svn.freebsd.org/changeset/base/208506

Log:
  Merge r208110:
  
  > Do not attempt to render a logrecord with length byte, until we have
  > decompressed all the bytes required.
  
  Requested by: phk

Modified:
  stable/8/usr.sbin/fifolog/lib/fifolog_reader.c
Directory Properties:
  stable/8/usr.sbin/fifolog/   (props changed)

Modified: stable/8/usr.sbin/fifolog/lib/fifolog_reader.c
==============================================================================
--- stable/8/usr.sbin/fifolog/lib/fifolog_reader.c      Mon May 24 15:12:12 
2010        (r208505)
+++ stable/8/usr.sbin/fifolog/lib/fifolog_reader.c      Mon May 24 15:26:40 
2010        (r208506)
@@ -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;
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to