blob: e870477b53888dfb69bd2d13fd96415c0bc5702b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#include "EXTERN.h"
#include "perl.h"
#include "XSUB.h"
#include "ppport.h"
#include "perlglue.h"
#define INTERRUPTHANDLE "libvxi11client"
extern int vxi11_enable_srq(bool enable, char* handle, void (*callback)(void));
static SV* perlcallback = NULL;
static void interruptcallback(void) {
//PUSHMARK(SP);
call_sv(perlcallback, G_DISCARD | G_NOARGS);
}
int glue_enable_srq(bool enable, SV* callback) {
perlcallback = callback;
return vxi11_enable_srq(enable, INTERRUPTHANDLE, interruptcallback);
}
|