Commit 78d424d7 authored by William Gropp's avatar William Gropp
Browse files

[svn-r10650] Fix error in computing read buffer size

parent c724aafe
......@@ -1388,7 +1388,10 @@ static int PMIUBufferedReadLine( PMIProcess *pentry, char *buf, int maxlen )
while (curlen < maxlen) {
if (nextChar == endChar) {
do {
n = read( fd, readbuf, sizeof(readbuf)-1 );
/* Carefully read data into buffer. This could be
written to read more at one time, but would then
need to know the size of the readbuf */
n = read( fd, readbuf, 1 );
} while (n == -1 && errno == EINTR);
if (n == 0) {
/* EOF */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment