Changeset 40774


Ignore:
Timestamp:
08/19/17 11:50:06 (6 years ago)
Author:
gost
Message:

cleaned up

File:
1 edited

Legend:

Unmodified
Added
Removed
  • titan/titan/frontenddev.h

    r40766 r40774  
    515515        {
    516516                count++;
    517                 //if(checkbox("DM520") == 0 && checkbox("DM525") == 0)
    518                 if(checkbox("xxxxxxxx") == 0)
    519                 {
    520                         //ioctl(node->fd, FE_GET_EVENT, &ev);
    521                         //if(ev.status & FE_HAS_LOCK)
    522                         //      return 0;
    523                         ioctl(node->fd, FE_READ_STATUS, &status);
    524                         if(status != 0)
    525                                 debug(200, "status=%d, fe_lock=%d", status, FE_HAS_LOCK);
    526 
    527                         if(errno == ERANGE)
    528                         {
    529                                 usleep(1000);
    530                                 continue;
    531                         }
    532 
    533                         if(status & FE_HAS_LOCK)
     517
     518                //ioctl(node->fd, FE_GET_EVENT, &ev);
     519                //if(ev.status & FE_HAS_LOCK)
     520                //      return 0;
     521                ioctl(node->fd, FE_READ_STATUS, &status);
     522                if(status != 0)
     523                        debug(200, "status=%d, fe_lock=%d", status, FE_HAS_LOCK);
     524
     525                if(errno == ERANGE)
     526                {
     527                        usleep(1000);
     528                        continue;
     529                }
     530
     531                if(status & FE_HAS_LOCK)
    534532        //              if(FE_HAS_SYNC | FE_HAS_LOCK)
    535                                 return 0;
    536                         }
    537                         else
    538                         {
    539                                 if(ioctl(node->fd, FE_GET_EVENT, &status) && (errno == EAGAIN))
    540                                 {
    541                                         usleep(1000);
    542                                         continue;
    543                                 }
    544                                 if (status & FE_HAS_LOCK)
    545                                         return 0;
    546                         }
    547                         usleep(1000);
     533                        return 0;
     534                usleep(1000);
    548535        }
    549536
Note: See TracChangeset for help on using the changeset viewer.