[coreboot] [v2] r4283 - trunk/coreboot-v2/util/cbfstool

svn at coreboot.org svn at coreboot.org
Wed May 13 22:11:04 CEST 2009


Author: ward
Date: 2009-05-13 22:11:04 +0200 (Wed, 13 May 2009)
New Revision: 4283

Modified:
   trunk/coreboot-v2/util/cbfstool/fs.c
Log:

This patch fixes a segfault when a file too large to fit is added to a rom
image.

Signed-off-by: Ward Vandewege <ward at gnu.org>
Acked-by: Myles Watson <mylesgw at gmail.com>




Modified: trunk/coreboot-v2/util/cbfstool/fs.c
===================================================================
--- trunk/coreboot-v2/util/cbfstool/fs.c	2009-05-13 20:08:28 UTC (rev 4282)
+++ trunk/coreboot-v2/util/cbfstool/fs.c	2009-05-13 20:11:04 UTC (rev 4283)
@@ -99,7 +99,7 @@
 {
 	/* walk the rom and find an empty file with a base > base, and a large enough size */
 	unsigned int offset = ntohl(rom->header->offset);
-	unsigned int ret = -1;
+	int ret = -1;
 	struct cbfs_file *c = NULL;
 	unsigned long nextoffset, truncoffset;
 	struct cbfs_file *newfile = NULL;





More information about the coreboot mailing list