summaryrefslogtreecommitdiff
path: root/ports/unix/guts/dup.c
diff options
context:
space:
mode:
authorAndrew Shadura <andrewsh@debian.org>2015-11-22 21:25:49 +0100
committerAndrew Shadura <andrewsh@debian.org>2015-11-22 21:25:49 +0100
commit6e7205c8f65c8bc03af8619c04b7179218eb1520 (patch)
tree0957dfac7dbf4a5a39adfe2777666037b7bdd0f3 /ports/unix/guts/dup.c
pseudo (1.7.4-1) unstable; urgency=low
* Initial release (Closes: #796973). # imported from the archive
Diffstat (limited to 'ports/unix/guts/dup.c')
-rw-r--r--ports/unix/guts/dup.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/ports/unix/guts/dup.c b/ports/unix/guts/dup.c
new file mode 100644
index 0000000..f03c2ad
--- /dev/null
+++ b/ports/unix/guts/dup.c
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2008-2010 Wind River Systems; see
+ * guts/COPYRIGHT for information.
+ *
+ * static int
+ * wrap_dup(int fd) {
+ * int rc = -1;
+ */
+ int save_errno;
+
+ rc = real_dup(fd);
+ save_errno = errno;
+ pseudo_debug(PDBGF_CLIENT, "dup: %d->%d\n", fd, rc);
+ pseudo_client_op(OP_DUP, 0, fd, rc, 0, 0);
+
+ errno = save_errno;
+/* return rc;
+ * }
+ */