From 0e3d3acd4e21e20acb7fe3966d54382b71323f59 Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Sat, 9 Jan 2021 12:38:54 +0700 Subject: [PATCH] Replace int_timer_on|off with int_(un)block. (#193) Both were used, but one just called the other, so simplify the API. --- inc/timerdefs.h | 2 -- src/loader.c | 8 ++++---- src/timer.c | 3 --- src/uraid.c | 4 ++-- 4 files changed, 6 insertions(+), 11 deletions(-) diff --git a/inc/timerdefs.h b/inc/timerdefs.h index 2c884c9..3961c6b 100644 --- a/inc/timerdefs.h +++ b/inc/timerdefs.h @@ -11,7 +11,5 @@ void int_io_open(int fd); void int_io_close(int fd); void int_block(void); void int_unblock(void); -void int_timer_off(void); -void int_timer_on(void); void int_init(void); #endif diff --git a/src/loader.c b/src/loader.c index d812f45..01a1e76 100644 --- a/src/loader.c +++ b/src/loader.c @@ -102,9 +102,9 @@ int do_system_call(LispPTR arg) #ifdef DEBUG printf(":: %s \n", cmd_str); #endif - int_timer_off(); + int_block(); result = system(cmd_str); - int_timer_on(); + int_unblock(); ARITH_SWITCH(result, lisp_result); return (lisp_result); } @@ -159,9 +159,9 @@ int exec_command(char *cmd_str) char ws[21][80]; int i, ii, cmd_length; - int_timer_off(); + int_block(); i = system(cmd_str); - int_timer_on(); + int_unblock(); return (i); } /*exec_command */ diff --git a/src/timer.c b/src/timer.c index 91a60ff..ccbef8f 100644 --- a/src/timer.c +++ b/src/timer.c @@ -631,9 +631,6 @@ void int_unblock() { #endif /* DOS */ } -void int_timer_on() { int_unblock(); } -void int_timer_off() { int_block(); } - #ifdef FLTINT /************************************************************************/ /* */ diff --git a/src/uraid.c b/src/uraid.c index 7a2c2a0..8cff309 100644 --- a/src/uraid.c +++ b/src/uraid.c @@ -878,7 +878,7 @@ int device_before_raid() { sigset_t signals; #endif - int_timer_off(); + int_block(); #ifdef XWINDOW /* So X events still get recognized. */ @@ -1127,7 +1127,7 @@ int device_after_raid() { flush_display_buffer(); #endif /* XWINDOW | DOS */ - int_timer_on(); + int_unblock(); *EmKbdAd068K = *EmRealUtilin68K = *EmKbdAd168K = *EmKbdAd268K = *EmKbdAd368K = *EmKbdAd468K = *EmKbdAd568K = KB_ALLUP; return (0);