diff options
Diffstat (limited to 'vxi11_server.c')
-rw-r--r-- | vxi11_server.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/vxi11_server.c b/vxi11_server.c index 520cb03..1a2a175 100644 --- a/vxi11_server.c +++ b/vxi11_server.c @@ -1,3 +1,4 @@ +#include "vxi11_server.h" #include "vxi11.h" #include "globals.h" #include "gpib.h" @@ -323,11 +324,13 @@ device_unlock_1_svc(Device_Link *argp, struct svc_req *rqstp) { return &result; } -void fireinterrupt() { - Device_SrqParms params; - params.handle.handle_val = inthandler; - params.handle.handle_len = strlen(inthandler); - device_intr_srq_1(¶ms, intclient); +void vxi11_fireinterrupt() { + if (intclient != NULL) { + Device_SrqParms params; + params.handle.handle_val = inthandler; + params.handle.handle_len = strlen(inthandler); + device_intr_srq_1(¶ms, intclient); + } } Device_Error * @@ -350,7 +353,6 @@ device_enable_srq_1_svc(Device_EnableSrqParms *argp, struct svc_req *rqstp) { #ifdef DEBUG printf("Interrupt handle set to %s\n", inthandler); #endif - fireinterrupt(); } } result.error = 0; |