Changes in kernel/genarch/src/multiboot/multiboot.c [3009164:ba1ea40] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/genarch/src/multiboot/multiboot.c
r3009164 rba1ea40 36 36 #include <genarch/multiboot/multiboot.h> 37 37 #include <config.h> 38 #include <stddef.h>39 38 #include <str.h> 40 39 … … 99 98 100 99 str_ncpy(buf, size, start, (size_t) (end - start)); 100 } 101 102 static void multiboot_cmdline(char *cmdline) 103 { 104 /* 105 * GRUB passes the command line in an escaped form. 106 */ 107 for (size_t i = 0, j = 0; 108 cmdline[i] && j < CONFIG_BOOT_ARGUMENTS_BUFLEN; 109 i++, j++) { 110 if (cmdline[i] == '\\') { 111 switch (cmdline[i + 1]) { 112 case '\\': 113 case '\'': 114 case '\"': 115 i++; 116 break; 117 } 118 } 119 bargs[j] = cmdline[i]; 120 } 101 121 } 102 122
Note:
See TracChangeset
for help on using the changeset viewer.