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

Sebastian Herbszt herbszt at gmx.de
Tue Feb 17 14:03:00 PST 2009


Michael Brown wrote:
> On Monday 16 February 2009 14:45:36 Gene Cumm wrote:
>> 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().
> 
> Is there an upper limit on the length of command strings?

syslinux_run_command() uses INT 22h AX=0003h (com32/lib/syslinux/run_command.c)
which copies the command line from ES:BX to "command_line" (core/comboot.inc).

parseconfig.inc:command_line    resb max_cmd_len+2      ; Command line buffer
config.inc:max_cmd_len  equ 2047                ; Must be &3; 2047 is the kernel limit

- Sebastian




More information about the Syslinux mailing list