Skip to content

Commit da57631

Browse files
committed
Ctypes has a slightly different interface to handle errno checking
1 parent 64a1327 commit da57631

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

code/ffi/datetime.ml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ let () = seal timeval
1616
type timezone
1717
let timezone : timezone structure typ = structure "timezone"
1818

19-
let gettimeofday = foreign "gettimeofday"
20-
(ptr timeval @-> ptr timezone @-> returning_checking_errno int)
19+
let gettimeofday = foreign "gettimeofday" ~check_errno:true
20+
(ptr timeval @-> ptr timezone @-> returning int)
2121

2222
let time' () = time (from_voidp time_t null)
2323

0 commit comments

Comments
 (0)