diff options
| author | LemonBoy <thatlemon@gmail.com> | 2019-10-03 15:32:47 +0200 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-10-03 17:07:53 -0400 |
| commit | 7640bec8e0e735eaba49087840b7f6e6b2dd74ab (patch) | |
| tree | b88b67a46a861962b17d32cf5570888d557b5af9 /lib/std/os/linux.zig | |
| parent | 7481a4ad089c0195fe238ef160ec667e3f604d22 (diff) | |
| download | zig-7640bec8e0e735eaba49087840b7f6e6b2dd74ab.tar.gz zig-7640bec8e0e735eaba49087840b7f6e6b2dd74ab.zip | |
Fix pipe syscall for MIPS
Diffstat (limited to 'lib/std/os/linux.zig')
| -rw-r--r-- | lib/std/os/linux.zig | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/std/os/linux.zig b/lib/std/os/linux.zig index e813519c68..46aeb28f2f 100644 --- a/lib/std/os/linux.zig +++ b/lib/std/os/linux.zig @@ -328,7 +328,9 @@ pub fn faccessat(dirfd: i32, path: [*]const u8, mode: u32, flags: u32) usize { } pub fn pipe(fd: *[2]i32) usize { - if (@hasDecl(@This(), "SYS_pipe")) { + if (builtin.arch == .mipsel) { + return syscall_pipe(fd); + } else if (@hasDecl(@This(), "SYS_pipe")) { return syscall1(SYS_pipe, @ptrToInt(fd)); } else { return syscall2(SYS_pipe2, @ptrToInt(fd), 0); |
