Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/init.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "watcher.h"

void (*eln2)(void (*)(void *), void *, double, int);
uint64_t (*eln2)(void (*)(void *), void *, double, int);

static const R_CallMethodDef callMethods[] = {
{"watcher_create", (DL_FUNC) &watcher_create, 3},
Expand All @@ -11,7 +11,7 @@ static const R_CallMethodDef callMethods[] = {

void attribute_visible R_init_watcher(DllInfo* dll) {
if (fsw_init_library() != FSW_OK) return;
eln2 = (void (*)(void (*)(void *), void *, double, int)) R_GetCCallable("later", "execLaterNative2");
eln2 = (uint64_t (*)(void (*)(void *), void *, double, int)) R_GetCCallable("later", "execLaterNative2");
R_registerRoutines(dll, NULL, callMethods, NULL, NULL);
R_useDynamicSymbols(dll, FALSE);
R_forceSymbols(dll, TRUE);
Expand Down
3 changes: 2 additions & 1 deletion src/watcher.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#define WATCHER_H

#include <stdarg.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
Expand All @@ -26,7 +27,7 @@ typedef struct watcher_cb_s {
unsigned int event_num;
} watcher_cb;

extern void (*eln2)(void (*)(void *), void *, double, int);
extern uint64_t (*eln2)(void (*)(void *), void *, double, int);

SEXP watcher_create(SEXP, SEXP, SEXP);
SEXP watcher_start_monitor(SEXP);
Expand Down
Loading