Thread: select() question

  1. #1
    Registered User
    Join Date
    May 2006

    select() question

    Hello.. I was wondering about different select() approach in my multi-client application which will use a lot of sockets at once..

    So instead of setting X sockets to fd_set (which has limitation 64 sockets on wins) and then calling select() for this fd_set, I made a class for each socket (every socket with own fd_set) and when I want to check if socket is readable/writeable/.. I just call select on fd_set of each socket.. This would mean I would have to call select() more times (for each socket) not only once for all sockets.. Would this slow down my program? It would make bypass fd_set limitation but would it affect the application speed?

    Thanks for answers

    Kind regards

  2. #2
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Yes, it would slow down your program. The 64 socket limit can be increased.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. another do while question
    By kbpsu in forum C++ Programming
    Replies: 3
    Last Post: 03-23-2009, 12:14 PM
  2. opengl DC question
    By SAMSAM in forum Game Programming
    Replies: 6
    Last Post: 02-26-2003, 09:22 PM
  3. Question on Select Case?
    By Wescb in forum C++ Programming
    Replies: 8
    Last Post: 12-11-2002, 11:11 PM
  4. Directional Keys - Useing in Console
    By RoD in forum C++ Programming
    Replies: 38
    Last Post: 10-06-2002, 04:42 PM
  5. scandir select function
    By dsl24 in forum C Programming
    Replies: 3
    Last Post: 04-12-2002, 10:58 AM