[syslinux] IP details in COM32 module

H. Peter Anvin hpa at zytor.com
Fri Jun 8 18:07:54 PDT 2007


Coe, Colin C. (Unix Engineer) wrote:
> After appending all the ip info I want to be passed to anaconda into __com32.cs_bounce, then printing __com32.cs_bounce only the first 32 chars are shown.  Also looking in ./com32/include/com32.h in "extern struct com32_sys_args" I saw "uint32_t cs_bounce_size" so I figured 32 chars, from your responce I gather I'm way off base.

You did something like fputs(__com32.cs_bounce, stdout); I presume (or
printf, or what have you.)

This will be translated into a write() call to the console, which calls
back into syslinux; that will use... (wait for it) the bounce buffer
internally in the library.

> I very confused as to why this string gets truncated at the 32 char mark...

See above.

Pretty much, any libc function which does I/O will clobber the bounce
buffer, and many that don't.  Consider it a very volatile,
single-threaded resource which is only supposed to be used right around
the intcall that invokes it.

In syslinux-3.50-pre* you can use the wrapper function
syslinux_run_command() to do that I believe you want to do; it's defined
in <syslinux/boot.h>.

	-hpa




More information about the Syslinux mailing list