elflink: Cleanup some warnings
authorLiu Aleaxander <Aleaxander@gmail.com>
Tue, 15 Mar 2011 20:19:33 +0000 (20:19 +0000)
committerMatt Fleming <matt.fleming@linux.intel.com>
Tue, 15 Mar 2011 21:13:42 +0000 (21:13 +0000)
Cleanup some unused variables, goto lables, and add the missing
header files.

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
Signed-off-by: Matt Fleming <matt.fleming@linux.intel.com>
com32/elflink/ldlinux/cli.c
com32/elflink/ldlinux/getadv.c
com32/elflink/ldlinux/ldlinux.c
com32/elflink/ldlinux/readconfig.c
core/elflink/execute.c

index 77d32cd..03befe5 100644 (file)
@@ -418,7 +418,6 @@ void process_command(const char *cmd, bool history)
        else
                execute(temp_cmd, KT_KERNEL);
 
-cleanup:
        free(argv);
        free(temp_cmd);
 }
index 456084b..5578313 100644 (file)
@@ -39,7 +39,7 @@
 const void *syslinux_getadv(int tag, size_t * size)
 {
     const uint8_t *p;
-    size_t left, len;
+    size_t left;
 
     p = syslinux_adv_ptr();
     left = syslinux_adv_size();
index b5a4409..a0e8459 100644 (file)
@@ -13,7 +13,7 @@
 static void enter_cmdline(void)
 {
        struct cli_command  *aux;
-       char *cmdline;
+       const char *cmdline;
 
        /* Enter endless command line prompt, should support "exit" */
        while (1) {
index 898ee19..c618dc0 100644 (file)
@@ -1124,7 +1124,6 @@ void parse_configs(char **argv)
     const char *filename;
     struct menu *m;
     struct menu_entry *me;
-    char *cmdline;
     dprintf("enter");
 
     empty_string = refstrdup("");
index 79dbc55..7e70323 100644 (file)
@@ -16,6 +16,8 @@
 #include <dprintf.h>
 
 #include <com32.h>
+#include <sys/exec.h>
+#include "core.h"
 #include "core-elf.h"
 
 /* Must match enum kernel_type */