[PATCH] use proper value for the first argument of select ()
Pavel Tsekov
ptsekov at gmx.net
Sat Aug 24 15:41:57 UTC 2002
PR> Please give more information how you tested your changes and what problems
PR> they fix. Just because something looks obvious in the code, it doesn't
PR> mean that the change doesn't need to be tested.
PR> Right now I'm trying to figure out how to test check_error_pipe(). It is
PR> called in the viewer. I don't want to spend time on repeating your
PR> testing, I'd prefer to know how you tested it.
1. Use the attached bad.tar.gz archive
The second entry in the tar is bad so the viewer can get some
input and won't quite at the beginning. Then when freeing the
file it calls check_error_pipe ().
2. Try to view it with internal viewer
3. Try with and without the patch
The mistake is that after the select () call the code checks fd 0 (stdin)
and it should check the pipe read end. I would agree with the code if the
read end of the pipe was duped to stdin but it is not.
Thanks! :)
Pavel Tsekov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bad.tar.gz
Type: application/x-gzip
Size: 4993 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20020824/f97f2031/attachment.bin>
More information about the mc-devel
mailing list