title: c select() function always return 1
body: <p>I am using select() function to listen the events from all file descriptors including stdin. The select function is always called in time but no matter whatever event happened and whatever fd triggers the event ,the select() function always returns 1. </p>
  
  <pre><code>    void startSelecting()
      {
         printf("ready! start listening all events\n");
        int current;
        while(is_running){
  
           do{
               current=select(1000,&amp;readset,NULL,NULL,NULL);
             }while(current==-1&amp;&amp;errno==EINTR);
                printf("file descriptor %d has event\n",current);
                processEvents(current);
  
          }
  
  
      }
  </code></pre>
  
  <p>So,that is,it always prints  "file descriptor 1 has event"...
  And,I am implementing C language Code.
  thank you guys</p>