removed some printf and commented code
This commit is contained in:
parent
4894cc9075
commit
53144b87f9
1 changed files with 4 additions and 12 deletions
16
src/main.c
16
src/main.c
|
@ -10,6 +10,7 @@
|
||||||
#include "debugger.h"
|
#include "debugger.h"
|
||||||
#include "hp48.h"
|
#include "hp48.h"
|
||||||
#include "x48_gui.h"
|
#include "x48_gui.h"
|
||||||
|
|
||||||
#ifdef GUI_IS_SDL1
|
#ifdef GUI_IS_SDL1
|
||||||
#include "resources.h"
|
#include "resources.h"
|
||||||
#endif
|
#endif
|
||||||
|
@ -89,9 +90,6 @@ int main( int argc, char** argv ) {
|
||||||
struct itimerval it;
|
struct itimerval it;
|
||||||
#ifdef GUI_IS_SDL1
|
#ifdef GUI_IS_SDL1
|
||||||
int rv, i;
|
int rv, i;
|
||||||
/* unsigned t1, t2; */
|
|
||||||
|
|
||||||
printf( "x48ng\n" );
|
|
||||||
|
|
||||||
// SDL Initialization
|
// SDL Initialization
|
||||||
SDLInit();
|
SDLInit();
|
||||||
|
@ -152,9 +150,6 @@ int main( int argc, char** argv ) {
|
||||||
|
|
||||||
// Create the HP-48 window
|
// Create the HP-48 window
|
||||||
SDLCreateHP();
|
SDLCreateHP();
|
||||||
|
|
||||||
// Some more initialization
|
|
||||||
printf( "init active stuff\n" );
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -165,7 +160,6 @@ int main( int argc, char** argv ) {
|
||||||
/*
|
/*
|
||||||
* install a handler for SIGALRM
|
* install a handler for SIGALRM
|
||||||
*/
|
*/
|
||||||
printf( "SIGALRM\n" );
|
|
||||||
sigemptyset( &set );
|
sigemptyset( &set );
|
||||||
sigaddset( &set, SIGALRM );
|
sigaddset( &set, SIGALRM );
|
||||||
sa.sa_handler = signal_handler;
|
sa.sa_handler = signal_handler;
|
||||||
|
@ -178,7 +172,6 @@ int main( int argc, char** argv ) {
|
||||||
/*
|
/*
|
||||||
* install a handler for SIGINT
|
* install a handler for SIGINT
|
||||||
*/
|
*/
|
||||||
printf( "SIGINT\n" );
|
|
||||||
sigemptyset( &set );
|
sigemptyset( &set );
|
||||||
sigaddset( &set, SIGINT );
|
sigaddset( &set, SIGINT );
|
||||||
sa.sa_handler = signal_handler;
|
sa.sa_handler = signal_handler;
|
||||||
|
@ -191,7 +184,6 @@ int main( int argc, char** argv ) {
|
||||||
/*
|
/*
|
||||||
* install a handler for SIGPIPE
|
* install a handler for SIGPIPE
|
||||||
*/
|
*/
|
||||||
printf( "SIGPIPE\n" );
|
|
||||||
sigemptyset( &set );
|
sigemptyset( &set );
|
||||||
sigaddset( &set, SIGPIPE );
|
sigaddset( &set, SIGPIPE );
|
||||||
sa.sa_handler = signal_handler;
|
sa.sa_handler = signal_handler;
|
||||||
|
@ -204,7 +196,6 @@ int main( int argc, char** argv ) {
|
||||||
/*
|
/*
|
||||||
* set the real time interval timer
|
* set the real time interval timer
|
||||||
*/
|
*/
|
||||||
printf( "int timer\n" );
|
|
||||||
int interval = 20000;
|
int interval = 20000;
|
||||||
it.it_interval.tv_sec = 0;
|
it.it_interval.tv_sec = 0;
|
||||||
it.it_interval.tv_usec = interval;
|
it.it_interval.tv_usec = interval;
|
||||||
|
@ -215,13 +206,14 @@ int main( int argc, char** argv ) {
|
||||||
/*
|
/*
|
||||||
* Set stdin flags to not include O_NDELAY and O_NONBLOCK
|
* Set stdin flags to not include O_NDELAY and O_NONBLOCK
|
||||||
*/
|
*/
|
||||||
printf( "stdin flags\n" );
|
|
||||||
flags = fcntl( STDIN_FILENO, F_GETFL, 0 );
|
flags = fcntl( STDIN_FILENO, F_GETFL, 0 );
|
||||||
flags &= ~O_NDELAY;
|
flags &= ~O_NDELAY;
|
||||||
flags &= ~O_NONBLOCK;
|
flags &= ~O_NONBLOCK;
|
||||||
fcntl( STDIN_FILENO, F_SETFL, flags );
|
fcntl( STDIN_FILENO, F_SETFL, flags );
|
||||||
|
|
||||||
printf( "start emulate\n" );
|
/************************/
|
||||||
|
/* Start emulation loop */
|
||||||
|
/************************/
|
||||||
do {
|
do {
|
||||||
if ( !exec_flags )
|
if ( !exec_flags )
|
||||||
emulate();
|
emulate();
|
||||||
|
|
Loading…
Reference in a new issue