Commit 666ab194 authored by vvb2060's avatar vvb2060 Committed by John Wu

Fix app request fifo wait

parent 71e37345
......@@ -215,10 +215,10 @@ int app_request(const shared_ptr<su_info> &info) {
exec_cmd("request", extras, info, false);
// Wait for data input for at most 70 seconds
int fd = xopen(fifo, O_RDONLY | O_CLOEXEC);
int fd = xopen(fifo, O_RDONLY | O_CLOEXEC | O_NONBLOCK);
struct pollfd pfd = {
.fd = fd,
.events = POLL_IN
.events = POLLIN
};
if (xpoll(&pfd, 1, 70 * 1000) <= 0) {
close(fd);
......
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