if( FD_ISSET(i, &rfds) )
FD_SET(i, &efds);
+ #if 0
for( int i = 0; i < nfd; i ++ ) {
if( FD_ISSET(i, &rfds) ) {
_SysDebug("FD%i", i);
}
}
+ #endif
// TODO: Support _SysSendMessage IPC?
int64_t timeout = Timing::GetTimeToNextEvent();
timeoutp = &timeout;
}
else {
- ::_SysDebug("Calling select with no timeout");
+ //::_SysDebug("Calling select with no timeout");
timeoutp = 0;
}
int rv = ::_SysSelect(nfd, &rfds, NULL, NULL/*&efds*/, timeoutp, 0);
+ #if 0
for( int i = 0; i < nfd; i ++ ) {
if( FD_ISSET(i, &rfds) ) {
_SysDebug("FD%i", i);
}
}
- _SysDebug("rv=%i, timeout=%lli", rv, timeout);
+ #endif
+ //_SysDebug("rv=%i, timeout=%lli", rv, timeout);
- Timing::CheckEvents();
-
- input->HandleSelect(rfds);
- IPC::HandleSelect(rfds);
-
- compositor->Redraw();
+ try {
+ Timing::CheckEvents();
+
+ input->HandleSelect(rfds);
+ IPC::HandleSelect(rfds);
+
+ compositor->Redraw();
+ }
+ catch(...) {
+ ::_SysDebug("Exception during select handling");
+ }
}
return 0;
}