+2010-01-28 18:25 Christos Zoulas <christos@zoulas.com>
+
+ * Fix core-dump from unbound loop:
+ https://bugzilla.redhat.com/show_bug.cgi?id=533245
+
2010-01-22 15:45 Christos Zoulas <christos@zoulas.com>
* print proper mime for crystal reports file
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: softmagic.c,v 1.137 2009/05/08 23:25:46 christos Exp $")
+FILE_RCSID("@(#)$File: softmagic.c,v 1.138 2009/10/19 13:10:20 christos Exp $")
#endif /* lint */
#include "magic.h"
buf = (const char *)s + offset;
end = last = (const char *)s + nbytes;
/* mget() guarantees buf <= last */
- for (lines = linecnt, b = buf; lines &&
+ for (lines = linecnt, b = buf; lines && b < end &&
((b = CAST(const char *,
memchr(c = b, '\n', CAST(size_t, (end - b)))))
|| (b = CAST(const char *,