Properly recover from EINTR/EAGAIN/... in control_read().

pull/2048/head
Christian Parpart 3 years ago committed by nick black
parent 19f8496221
commit fd340d9e47

@ -1562,7 +1562,7 @@ control_read(int ttyfd, query_state* qstate){
free(buf); free(buf);
//fprintf(stderr, "at end, derived terminal %d\n", qstate->qterm); //fprintf(stderr, "at end, derived terminal %d\n", qstate->qterm);
return 0; return 0;
}else if(r < 0){ }else if (r < 0 && (errno != EINTR && errno != EAGAIN && errno != EBUSY && errno != EWOULDBLOCK)){
goto err; goto err;
} }
} }

Loading…
Cancel
Save