Skip to content

Commit 274051f

Browse files
authored
Merge pull request #354 from mirage/fix-miou
Use String.get_uint_16 instead of get_int_16 which leads to a bad id for the packet
2 parents f9bbebd + f59c72b commit 274051f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

miou/client/dns_client_miou_unix.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ module Transport = struct
139139
if String.length str > 4 then begin
140140
match fd with
141141
| `Tls fd ->
142-
let id = String.get_int16_be str 2 in
142+
let id = String.get_uint16_be str 2 in
143143
send_recv_tls ~timeout ~id fd str
144144
| `Udp fd | `Tcp fd ->
145145
let fd = Miou_unix.to_file_descr fd in

0 commit comments

Comments
 (0)