summaryrefslogtreecommitdiff
path: root/apl9.h
diff options
context:
space:
mode:
authorPeter Mikkelsen <petermikkelsen10@gmail.com>2022-05-16 07:05:17 +0000
committerPeter Mikkelsen <petermikkelsen10@gmail.com>2022-05-16 07:05:17 +0000
commit5c384cab27113e74c998811d85f65700c0827060 (patch)
tree7d04516e7d09d4ffdbeb373874a08c5bf23619ba /apl9.h
parentfd3f483368ec3c52e00260ae2941b6c0552473cf (diff)
Implement timeouts for receive
Diffstat (limited to 'apl9.h')
-rw-r--r--apl9.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/apl9.h b/apl9.h
index e56014b..bf36f52 100644
--- a/apl9.h
+++ b/apl9.h
@@ -52,6 +52,7 @@ typedef enum
ELength = 5,
EValue = 6,
EDomain = 11,
+ ETimeout = 12, /* not in dyalog */
ENotImplemented = 100, /* not in dyalog */
} errorCodes;
@@ -236,10 +237,12 @@ struct ThreadData
Mail *mail;
Mail *lastmail;
int lasterror;
+ int timeout; /* number of milli seconds to timeout */
+ int timedout; /* true if the recv timed out */
Rune *lasterrormsg;
ErrorGuard *globalerrorguard;
QLock lock;
- Rendez empty;
+ Rendez newmail;
};
struct Mail