URI: 
       tDon't spin on request/out/<ID> if we echo anything other than '0' or '1' - ratox - FIFO based tox client
   DIR Log
   DIR Files
   DIR Refs
   DIR README
   DIR LICENSE
       ---
   DIR commit cdb4a8e44efb410b927b847d5b3b1c8f953d78c0
   DIR parent 2bac75b6141c34010bbf679e732ad86d6dacfd6a
  HTML Author: sin <sin@2f30.org>
       Date:   Fri, 10 Oct 2014 11:00:50 +0100
       
       Don't spin on request/out/<ID> if we echo anything other than '0' or '1'
       
       Diffstat:
         M ratox.c                             |       6 +++++-
       
       1 file changed, 5 insertions(+), 1 deletion(-)
       ---
   DIR diff --git a/ratox.c b/ratox.c
       t@@ -1615,6 +1615,7 @@ loop(void)
                char c;
                fd_set rfds;
                struct timeval tv;
       +        struct file reqfifo;
        
                t0 = time(NULL);
                printout("DHT > Connecting\n");
       t@@ -1804,7 +1805,10 @@ loop(void)
                                rtmp = TAILQ_NEXT(req, entry);
                                if (FD_ISSET(req->fd, &rfds) == 0)
                                        continue;
       -                        if (read(req->fd, &c, 1) != 1)
       +                        reqfifo.name = req->idstr;
       +                        reqfifo.flags = O_RDONLY | O_NONBLOCK;
       +                        if (fiforead(gslots[REQUEST].fd[OUT], &req->fd, reqfifo,
       +                                     &c, 1) != 1)
                                        continue;
                                if (c != '0' && c != '1')
                                        continue;