From: Sebastian Herbszt Date: Tue, 22 Jul 2008 15:09:55 +0000 (+0200) Subject: parseconfig, ui: store the label name unmangled X-Git-Tag: syslinux-3.72-pre1~25^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=559ea7abec1acb497eca0bd74a583713e425302b;p=platform%2Fupstream%2Fsyslinux.git parseconfig, ui: store the label name unmangled Store the label names unmangled and match those against command_line. - Sebastian Signed-off-by: H. Peter Anvin --- diff --git a/core/parseconfig.inc b/core/parseconfig.inc index 7fb6ddf..843a733 100644 --- a/core/parseconfig.inc +++ b/core/parseconfig.inc @@ -307,7 +307,16 @@ pc_label: call commit_vk ; Commit any current vkernel rep stosw call pc_getline mov di,VKernelBuf+vk_vname - call mangle_name ; Mangle virtual name + mov cx,FILENAME_MAX-1 +.loop: + lodsb + cmp al,' ' + jna .done + mov [di],al + inc di + dec cx + jnz .loop +.done: mov byte [VKernel],1 ; We've seen a "label" statement mov si,VKernelBuf+vk_vname ; By default, rname == vname mov di,VKernelBuf+vk_rname diff --git a/core/ui.inc b/core/ui.inc index f593ce1..0ff9d10 100644 --- a/core/ui.inc +++ b/core/ui.inc @@ -308,12 +308,26 @@ vk_check: sub di,cx ; Return to beginning of buf push si - mov si,KernelName + mov si,command_line mov cx,FILENAME_MAX - es repe cmpsb +.loop: + dec cx + jz .done + lodsb + mov ah,[di] + inc di + cmp ah,al + je .match + jmp .nomatch +.match: + cmp al,' ' + jna .done + jmp .loop +.nomatch: pop si - je .found jmp .scan +.done: + pop si ; ; We *are* using a "virtual kernel"