Original Post
Using select() for the first time and I just have a question that I really havn't found an explanation for in my books or online. So, first, let me see if I have this correct. When using select, you set the FD masks for each socket and select() simply tells you when an event has happened. You then iterate through your clients(assuming this is server side) and use the FD_ISSET macro to find out what socket has what event and then deal with it appropriately. Rinse and repeat for as many events as you have. So, do the flags have to be reset each time you deal with an event? (i.e. setting them back to zero) or do you just have to set them up once and then forget about them? And do I have the general jist of the concept correct? Thanks.