summaryrefslogtreecommitdiffstats
path: root/src/core/exec.c
Commit message (Collapse)AuthorAgeFilesLines
* [script] Allow for DOS-style line endings in scriptsMichael Brown2009-06-031-2/+3
| | | | | | | | | | | | | | | Windows text editors such as Notepad tend to use CRLF line endings, which breaks gPXE's signature detection for script images. Since scripts are usually very small, they end up falling back to being detected as valid PXE executable images (since there are no signature checks for PXE executables). Executing text files as x86 machine code tends not to work well. Fix by allowing for any isspace() character to terminate the "#!gpxe" signature, and by ensuring that CR characters get stripped during command line parsing. Suggested-by: Shao Miller <Shao.Miller@yrdsb.edu.on.ca>
* [legal] Add a selection of FILE_LICENCE declarationsMichael Brown2009-05-181-0/+2
| | | | | Add FILE_LICENCE declarations to almost all files that make up the various standard builds of gPXE.
* [tables] Redefine methods for accessing linker tablesMichael Brown2009-03-131-6/+1Star
| | | | | | | | | | | | | | | Intel's C compiler (icc) chokes on the zero-length arrays that we currently use as part of the mechanism for accessing linker table entries. Abstract away the zero-length arrays, to make a port to icc easier. Introduce macros such as for_each_table_entry() to simplify the common case of iterating over all entries in a linker table. Represent table names as #defined string constants rather than unquoted literals; this avoids visual confusion between table names and C variable or type names, and also allows us to force a compilation error in the event of incorrect table names.
* [cmdline] Add setting expansion using ${...} syntaxMichael Brown2008-07-271-2/+96
| | | | | | | | | Allow settings to be expanded in arbitrary commands, such as kernel http://10.0.0.1/boot.php?uuid=${uuid} Also add the "echo" command, as being the easiest way to test this features.
* Use stdio.h instead of vsprintf.hMichael Brown2007-01-191-1/+1
|
* Ignore comment lines.Michael Brown2007-01-121-3/+5
| | | | Avoid returning errors for comments and empty lines.
* Add "name" field to struct device to allow human-readable hardware deviceMichael Brown2007-01-101-2/+4
| | | | | | | | | | | names. Add "dev" pointer in struct net_device to tie network interfaces back to a hardware device. Force natural alignment of data types in __table() macros. This seems to prevent gcc from taking the unilateral decision to occasionally increase their alignment (which screws up the table packing).
* Use common symbols to avoid dragging in getopt.o unless a getopt-usingMichael Brown2006-12-191-0/+4
| | | | command is linked in.
* Cope with system("").Michael Brown2006-12-081-6/+12
|
* D'oh d'oh d'oh d'oh d'oh d'oh d'oh d'oh d'ohMichael Brown2006-12-081-3/+9
|
* Added execv() and system().Michael Brown2006-12-081-0/+139