diff --git a/net_util/src/tap.rs b/net_util/src/tap.rs index d700bc3f7..07a6e072c 100644 --- a/net_util/src/tap.rs +++ b/net_util/src/tap.rs @@ -124,7 +124,7 @@ impl Tap { // Open calls are safe because we give a constant null-terminated // string and verify the result. libc::open( - b"/dev/net/tun\0".as_ptr() as *const c_char, + c"/dev/net/tun".as_ptr() as *const c_char, flags.unwrap_or(libc::O_RDWR | libc::O_NONBLOCK | libc::O_CLOEXEC), ) };