projects
/
platform
/
upstream
/
linaro-gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
376273c
)
entered into RCS
author
rms
<rms@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 28 Jul 1992 02:18:03 +0000
(
02:18
+0000)
committer
rms
<rms@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 28 Jul 1992 02:18:03 +0000
(
02:18
+0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@1697
138bc75d
-0d04-0410-961f-
82ee72b054a4
gcc/collect2.c
patch
|
blob
|
history
diff --git
a/gcc/collect2.c
b/gcc/collect2.c
index
5915cf0
..
532f182
100644
(file)
--- a/
gcc/collect2.c
+++ b/
gcc/collect2.c
@@
-206,6
+206,25
@@
generic *xmalloc ();
extern char *index ();
extern char *rindex ();
\f
+#ifdef NO_DUP2
+dup2 (oldfd, newfd)
+ int oldfd;
+ int newfd;
+{
+ int fdtmp[256];
+ int fdx = 0;
+ int fd;
+
+ if (oldfd == newfd)
+ return 0;
+ close (newfd);
+ while ((fd = dup (oldfd)) != newfd) /* good enough for low fd's */
+ fdtmp[fdx++] = fd;
+ while (fdx > 0)
+ close (fdtmp[--fdx]);
+}
+#endif
+
char *
my_strerror (e)
int e;