[syslinux] [PATCH] cmd.c32: new module to just execute a command

Gene Cumm gene.cumm at gmail.com
Mon Feb 16 06:45:36 PST 2009


On Mon, Feb 16, 2009 at 3:49 AM, Michael Brown <mcb30 at etherboot.org> wrote:
> Trivial module to execute an arbitrary command.

Similar in function to the alias module I created back in October.
The key differences I notice are that yours appears simpler, mine
could also be tested as a Linux binary, yours uses sprintf versus mine
using memcpy and mine would definitely not pass a command string that
was too long to syslinux_run_command().  I'm not sure if it's even
theoretically possible to even do so though.  It's probably an
unnecessary but paranoid check.

I originally created mine because I often had multiple labels doing
similar tasks with either no or minor variations (short name vs long
name; main vs add an additional parameter) and there's no way for one
label to call another (as far as I could tell).

Including something that provides this functionality into Syslinux
would probably provide benefit for anyone that has multiple similar
labels.

-- 
-Gene

"No one ever says, 'I can't read that ASCII E-mail you sent me.'"




More information about the Syslinux mailing list