summaryrefslogtreecommitdiff
path: root/toolchain/uclibc/patches/0.9.34-git/0001-fix-for-pipe-on-sparc.patch
blob: 5b13033a335479d32c7ed3b5c2424d594dd36486 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
From c8f3e4d51080814a4251021277dd64c4d22263ae Mon Sep 17 00:00:00 2001
From: Waldemar Brodkorb <wbx@openadk.org>
Date: Tue, 19 Aug 2014 21:02:59 +0200
Subject: [PATCH 1/5] fix for pipe() on sparc

When using something like this:
 $ echo foo|grep foo|wc -l
with mksh shell, you get an runtime error.

Glibc and klibc does not do these extra check.
After removing this check using double pipes work fine.
Tested with Qemu 2.1.0.

Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
---
 libc/sysdeps/linux/sparc/pipe.S | 2 --
 1 file changed, 2 deletions(-)

diff --git a/libc/sysdeps/linux/sparc/pipe.S b/libc/sysdeps/linux/sparc/pipe.S
index 09ef322..b085faf 100644
--- a/libc/sysdeps/linux/sparc/pipe.S
+++ b/libc/sysdeps/linux/sparc/pipe.S
@@ -35,8 +35,6 @@ pipe:
 	/* sanity check arguments */
 	tst	%i0
 	be	.Lerror
-	 orcc	%i1,%g0,%o1
-	be	.Lerror
 	 mov	%i2,%o0
 
 	/* Do the system call */
-- 
1.8.5.2 (Apple Git-48)