diff options
Diffstat (limited to 'ot_fdstate.h')
| -rw-r--r-- | ot_fdstate.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ot_fdstate.h b/ot_fdstate.h index 88f685d..c09f018 100644 --- a/ot_fdstate.h +++ b/ot_fdstate.h | |||
| @@ -31,6 +31,10 @@ size_t fdstate_slots(void); | |||
| 31 | generation to quote when asking for it back. expiry of 0 never expires. */ | 31 | generation to quote when asking for it back. expiry of 0 never expires. */ |
| 32 | uint32_t fdstate_open(int fd, void *cookie, ot_time expiry); | 32 | uint32_t fdstate_open(int fd, void *cookie, ot_time expiry); |
| 33 | 33 | ||
| 34 | /* Which generation a descriptor currently carries, to check an event that | ||
| 35 | was handed out earlier against the connection living there now. */ | ||
| 36 | uint32_t fdstate_generation(int fd); | ||
| 37 | |||
| 34 | /* Ask for exclusive use. Returns 0 if the descriptor has been recycled since | 38 | /* Ask for exclusive use. Returns 0 if the descriptor has been recycled since |
| 35 | generation was handed out, or if somebody else is using it. */ | 39 | generation was handed out, or if somebody else is using it. */ |
| 36 | int fdstate_claim(int fd, uint32_t generation); | 40 | int fdstate_claim(int fd, uint32_t generation); |
