aboutsummaryrefslogtreecommitdiffstats
path: root/com32/mboot/mboot.c
diff options
context:
space:
mode:
Diffstat (limited to 'com32/mboot/mboot.c')
-rw-r--r--com32/mboot/mboot.c22
1 files changed, 16 insertions, 6 deletions
diff --git a/com32/mboot/mboot.c b/com32/mboot/mboot.c
index d008da0f..915c7857 100644
--- a/com32/mboot/mboot.c
+++ b/com32/mboot/mboot.c
@@ -36,7 +36,7 @@
struct multiboot_info mbinfo;
struct syslinux_pm_regs regs;
-struct my_options opt;
+struct my_options opt, set;
struct module_data {
void *data;
@@ -161,11 +161,21 @@ int main(int argc, char *argv[])
argv++;
while (*argv) {
- if (!strcmp(*argv, "-solaris"))
- opt.solaris = true;
- else if (!strcmp(*argv, "-aout"))
- opt.aout = true;
- else
+ bool v = true;
+ const char *p = *argv;
+
+ if (!memcmp(p, "-no", 3)) {
+ v = false;
+ p += 3;
+ }
+
+ if (!strcmp(p, "-solaris")) {
+ opt.solaris = v;
+ set.solaris = true;
+ } else if (!strcmp(p, "-aout")) {
+ opt.aout = v;
+ set.aout = true;
+ } else
break;
argv++;
}