All of lore.kernel.org
 help / color / mirror / Atom feed
* Commands not executed in the else branch
@ 2009-04-27  4:52 Pavel Roskin
  2009-04-27  6:15 ` Bean
  0 siblings, 1 reply; 4+ messages in thread
From: Pavel Roskin @ 2009-04-27  4:52 UTC (permalink / raw)
  To: grub-devel

Hello!

While testing the new "test" command, I have found that the "else"
branch is not executed in some cases.  "echo" and "set" are executed,
but other commands are not.  Even "hello" is not working.  The problem
is not specific to the "test" command.  I can do it with "search" as
well:

grub> if search -f /; then echo 0; else hello; fi
error: no such device
grub> if search -f /; then echo 0; else echo Hello World; fi
Hello World
error: no such device
grub> if search -f /; then echo 0; else echo 1; hello; echo 2; fi
1
2
error: no such device
grub>

The problem disappears after there is a true condition in the "if" part.

-- 
Regards,
Pavel Roskin



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-05-03  6:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-27  4:52 Commands not executed in the else branch Pavel Roskin
2009-04-27  6:15 ` Bean
2009-04-27 14:10   ` Pavel Roskin
2009-05-03  6:49     ` Bean

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.