summaryrefslogtreecommitdiff
path: root/opentracker.c
diff options
context:
space:
mode:
authorerdgeist <>2006-12-08 22:53:32 +0000
committererdgeist <>2006-12-08 22:53:32 +0000
commit932242eee7d99559bf8e0b4cec2b140f567a8149 (patch)
treedfd076af04012effb9f98d19363e8299d14a042c /opentracker.c
parentdc025776dd77e2f8da1e2ee0667962115bf90bc8 (diff)
Logic now actually initialized and deinitialized
Diffstat (limited to 'opentracker.c')
-rw-r--r--opentracker.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/opentracker.c b/opentracker.c
index 10b7d87..ac3fda1 100644
--- a/opentracker.c
+++ b/opentracker.c
@@ -224,8 +224,11 @@ bailout:
224} 224}
225 225
226void graceful( int s ) { 226void graceful( int s ) {
227 signal( SIGINT, SIG_IGN ); 227 if( s == SIGINT ) {
228 deinit_logic(); 228 signal( SIGINT, SIG_IGN);
229 deinit_logic();
230 exit( 0 );
231 }
229} 232}
230 233
231int main() 234int main()
@@ -245,7 +248,8 @@ int main()
245 panic("io_fd"); 248 panic("io_fd");
246 249
247 signal( SIGINT, graceful ); 250 signal( SIGINT, graceful );
248 init_logic( "." ); 251 if( init_logic( "." ) == -1 )
252 panic("Logic not started");
249 253
250 io_wantread(s); 254 io_wantread(s);
251 255