use the return value from read
This commit is contained in:
parent
31c9d86dba
commit
1e0f42d3b6
|
@ -3390,7 +3390,7 @@ FString FTerm::getAnswerbackMsg()
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
usleep(150000); // wait 150 ms
|
usleep(150000); // wait 150 ms
|
||||||
// read the answerback message
|
// read the answerback message
|
||||||
read(fileno(stdin), &temp, sizeof(temp)-1);
|
if ( read(fileno(stdin), &temp, sizeof(temp)-1) > 0 )
|
||||||
answerback = temp;
|
answerback = temp;
|
||||||
}
|
}
|
||||||
return answerback;
|
return answerback;
|
||||||
|
@ -3412,7 +3412,7 @@ FString FTerm::getSecDA()
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
usleep(150000); // wait 150 ms
|
usleep(150000); // wait 150 ms
|
||||||
// read the answer
|
// read the answer
|
||||||
read(fileno(stdin), &temp, sizeof(temp)-1);
|
if ( read(fileno(stdin), &temp, sizeof(temp)-1) > 0 )
|
||||||
sec_da = temp;
|
sec_da = temp;
|
||||||
}
|
}
|
||||||
return sec_da;
|
return sec_da;
|
||||||
|
|
Loading…
Reference in New Issue