summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
9e7dbe4)
struct pollfd *pollfd;
int i;
int num_rdy;
struct pollfd *pollfd;
int i;
int num_rdy;
pollfd = malloc(fd_pairs->num_pairs * sizeof(struct pollfd));
pollfd = malloc(fd_pairs->num_pairs * sizeof(struct pollfd));
num_rdy = poll(pollfd, fd_pairs->num_pairs, -1);
if(num_rdy == -1) {
perror("Poll error");
num_rdy = poll(pollfd, fd_pairs->num_pairs, -1);
if(num_rdy == -1) {
perror("Poll error");
break;
case POLLPRI:
/* Take care of high priority channels first. */
break;
case POLLPRI:
/* Take care of high priority channels first. */
- for(i=0;i<fd_pairs->num_pairs;i++) {
- switch(pollfd[i].revents) {
- case POLLIN:
- /* Take care of low priority channels. */
- break;
- default:
+ if(!high_prio) {
+ for(i=0;i<fd_pairs->num_pairs;i++) {
+ switch(pollfd[i].revents) {
+ case POLLIN:
+ /* Take care of low priority channels. */
+ break;
+ }
+ }