Changeset 1744 for zzuf/trunk


Ignore:
Timestamp:
Feb 9, 2007, 2:52:59 AM (13 years ago)
Author:
Sam Hocevar
Message:
  • Improved win32 pipes.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • zzuf/trunk/src/zzuf.c

    r1743 r1744  
    935935    memset(&sinfo, 0, sizeof(sinfo));
    936936    sinfo.cb = sizeof(sinfo);
    937     DuplicateHandle(pid, (HANDLE)_get_osfhandle(fd[j][0]), pid,
     937    DuplicateHandle(pid, (HANDLE)_get_osfhandle(fd[0][1]), pid,
    938938        /* FIXME */ &sinfo.hStdInput, 0, TRUE, DUPLICATE_SAME_ACCESS);
    939     DuplicateHandle(pid, (HANDLE)_get_osfhandle(fd[j][1]), pid,
     939    DuplicateHandle(pid, (HANDLE)_get_osfhandle(fd[1][1]), pid,
    940940                    &sinfo.hStdError, 0, TRUE, DUPLICATE_SAME_ACCESS);
    941     DuplicateHandle(pid, (HANDLE)_get_osfhandle(fd[j][2]), pid,
     941    DuplicateHandle(pid, (HANDLE)_get_osfhandle(fd[2][1]), pid,
    942942                    &sinfo.hStdOutput, 0, TRUE, DUPLICATE_SAME_ACCESS);
     943    sinfo.dwFlags = STARTF_USESTDHANDLES;
    943944    ret = CreateProcess(NULL, opts->newargv[0], NULL, NULL, FALSE,
    944945                        CREATE_SUSPENDED, NULL, NULL, &sinfo, &pinfo);
Note: See TracChangeset for help on using the changeset viewer.