[syslinux] GSOC 2008 ELF Loader

Chad Z. Hower Chad at Hower.org
Sun May 17 00:25:08 PDT 2009


H. Peter Anvin wrote:
> As command line parameters.  And yes, you're probably correct in that
> regards.


In its current form its not practically usable then. It totally ignores 
command line parameters as far as I can see.

int main(int argc, char **argv) {
	int done = 0;
	int res;
	char command[MAX_COMMAND_SIZE] = {0};

	// Open a standard r/w console
	openconsole(&dev_stdcon_r, &dev_stdcon_w);

	res = exec_init();
	if (res != 0) {
		printf("Failed to initialize the execution environment.\n");
		return res;
	} else {
		printf("Execution environment initialized successfully.\n");
	}


	printf("\nFor a list of available commands, type 'help'.\n");

	do {
		print_prompt();
		read_command(command, MAX_COMMAND_SIZE);
		done = process_command(command);

	} while (!done);

	exec_term();

	return 0;
}




More information about the Syslinux mailing list