X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=src%2Femuconsole.c;h=3dcdf89e07088073010c351e5188a2eeec09f59b;hb=45be0d02186f8c48dc3705de2a71ade93705ae1d;hp=a3f563c71c29ee7466b1e805fbf829aa891aad05;hpb=581d60d73af5ae616f5c4f193de73ac56b257888;p=emu8051.git diff --git a/src/emuconsole.c b/src/emuconsole.c index a3f563c..3dcdf89 100644 --- a/src/emuconsole.c +++ b/src/emuconsole.c @@ -33,6 +33,8 @@ #include "hexfile.h" #include "keyboard.h" +extern struct options_t options; + /* Capitalize all letters in buffer */ static void Capitalize(char *buffer) @@ -451,22 +453,16 @@ TooMuchParameters: int main(int argc, char **argv) { - char *hex_file; - - ParseCommandLineOptions(argc, argv); + parse_command_line_options(argc, argv); cpu8051_init(); - hex_file = get_hex_filename(); - - if (hex_file != NULL) - LoadHexFile(hex_file); + if (options.filename != NULL) + LoadHexFile(options.filename); console_main(); -#ifdef EMU8051_DEBUG - printf("End of program.\n"); -#endif + log_info("Terminate"); return 0; }