fix TUNSETIFF constant

This commit is contained in:
Motiejus Jakštys 2024-10-10 21:35:50 -04:00
parent dc7f35ab7b
commit 43f2a6dcb8
1 changed files with 2 additions and 2 deletions

View File

@ -7,7 +7,7 @@ const log = std.log.scoped(.nyotun);
const IFF_TUN = 0x0001; // <linux/if_tun.h>
const IFF_NO_PI = 0x1000; // <linux/if_tun.h>
const TUNSETIFF = 0x800454ca; // same value on all archs, see go/src/syscall/*.go
const TUNSETIFF = 0x400454ca; // compile a C program, run and see
dev: [posix.IFNAMESIZE - 1:0]u8,
tunFile: posix.fd_t,
@ -56,7 +56,7 @@ pub fn close(self: *Tunnel) void {
const Tunnel = @This();
test "init tunnel" {
test "init" {
var tun = try init("nyotun");
tun.close();
}