[syslinux:elflink] elflink: Don't pass NULL to spawn_load()

syslinux-bot for Matt Fleming matt.fleming at linux.intel.com
Mon Mar 14 15:33:42 PDT 2011


Commit-ID:  2adb4a29248b8def7a967802ec1595024e8b77d6
Gitweb:     http://syslinux.zytor.com/commit/2adb4a29248b8def7a967802ec1595024e8b77d6
Author:     Matt Fleming <matt.fleming at linux.intel.com>
AuthorDate: Mon, 7 Mar 2011 21:52:54 +0000
Committer:  Matt Fleming <matt.fleming at linux.intel.com>
CommitDate: Tue, 8 Mar 2011 19:17:59 +0000

elflink: Don't pass NULL to spawn_load()

As spawn_load() dereferences the 'argv' parameter it really doesn't
expect it to be NULL.

Signed-off-by: Matt Fleming <matt.fleming at linux.intel.com>


---
 com32/lib/sys/module/exec.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/com32/lib/sys/module/exec.c b/com32/lib/sys/module/exec.c
index 30a61c0..0e7aa3f 100644
--- a/com32/lib/sys/module/exec.c
+++ b/com32/lib/sys/module/exec.c
@@ -387,8 +387,10 @@ int module_load_dependencies(const char *name,const char *dep_file)
 		i++;	/* skip a space */
 
 		if (strlen(temp_name)) {
+			char *argv[2] = { NULL, NULL };
+
 			module_load_dependencies(temp_name, MODULES_DEP);
-			if (spawn_load(temp_name, NULL) < 0)
+			if (spawn_load(temp_name, argv) < 0)
 				continue;
 		}
 	}



More information about the Syslinux-commits mailing list