- poll(&pfd, 1, 10000);
- sleep(5); /* HACK to allow ES buffer to drain */
- already_empty = 1;
-// if (::ioctl(m_fd_dest, PVR_COMMIT) < 0 && errno == EINTR)
-// continue;
- eDebug("commit done");
- /* well check again */
- continue;
+ switch (poll(&pfd, 1, 250)) // wait for 250ms
+ {
+ case 0:
+ eDebug("wait for driver eof timeout");
+ continue;
+ case 1:
+ eDebug("wait for driver eof ok");
+ break;
+ default:
+ eDebug("wait for driver eof aborted by signal");
+ continue;
+ }