aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--winsup/cygwin/dtable.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/dtable.cc b/winsup/cygwin/dtable.cc
index d995c7b..3b718f3 100644
--- a/winsup/cygwin/dtable.cc
+++ b/winsup/cygwin/dtable.cc
@@ -562,7 +562,7 @@ dtable::find_fifo (ATOM hill)
SetResourceLock (LOCK_FD_LIST, READ_LOCK, "dup");
for (unsigned i = 0; i < size; i++)
{
- fhandler_base *fh = fds[0];
+ fhandler_base *fh = fds[i];
if (fh && fh->isfifo () && ((fhandler_fifo *) fh)->get_atom () == hill)
return (fhandler_fifo *) fh;
}