aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Fleming <matt.fleming@intel.com>2012-07-06 15:36:56 +0100
committerMatt Fleming <matt.fleming@intel.com>2012-07-19 15:55:09 +0100
commitf351d07ddc7f1d7ed786d88f5725db20ef288439 (patch)
tree4abfe33784ec138eec367028bcae33be4a43aae5
parent5441637e53c663764612a708ad75b00d3229c1a5 (diff)
downloadsyslinux-f351d07ddc7f1d7ed786d88f5725db20ef288439.tar.gz
syslinux-f351d07ddc7f1d7ed786d88f5725db20ef288439.tar.xz
syslinux-f351d07ddc7f1d7ed786d88f5725db20ef288439.zip
ldlinux: Return immediately after we execute() a command
If we successfully lookup the filetype of a command we need to return once we've called execute(), otherwise we'll also end up calling new_linux_kernel(). Reported-by: Sebastian Herbszt <herbszt@gmx.de> Signed-off-by: Matt Fleming <matt.fleming@intel.com>
-rw-r--r--com32/elflink/ldlinux/execute.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/com32/elflink/ldlinux/execute.c b/com32/elflink/ldlinux/execute.c
index f713eb13..5d128cbb 100644
--- a/com32/elflink/ldlinux/execute.c
+++ b/com32/elflink/ldlinux/execute.c
@@ -86,6 +86,7 @@ void execute(const char *cmdline, enum kernel_type type)
if (!strcmp(kernel + 1, *pp)) {
/* Strip the type specifier and retry */
execute(p, type);
+ return;
}
}
}