× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Re: Value of select() descriptor count.
  • From: John Dorn <jdorn@xxxxxxxxxx>
  • Date: Tue, 04 Nov 1997 10:52:23 -0500
  • Organization: I/NET, Inc.

Sorry for the previous incomplete message (keyboard snafu).

I believe it is the maximum socket descriptor being checked plus one
and is scoped to the activation group (for our code we only use one
activation group within our job).  For example if an application
was going to check two sockets for a request the following logic
could be used:
   Desc1 = socket(...);
   Desc2 = socket(...);
   
   SelectDesc = max(Desc1,Desc2) + 1;
   FD_ZERO(&ReadSet);
   FD_SET(Desc1,&ReadSet);
   FD_SET(Desc2,&ReadSet);
   select(SelectDesc,&ReadSet,NULL,NULL,NULL);

Hope this helps,

John Dorn
I/NET, Inc.

Jeffrey M. Silberberg wrote:
> 
>  Mark & All Memers,
> 
>         How does one interupt this ;
> 
> max_descriptor
> (Input) Descriptors are numbered starting at zero, so the max_descriptor
> parameter must specify a value that is one greater than the largest
> descriptor number that is to be tested.
> 
>         In a select(max_descriptor, read_sl, write_sl, excpt_sl, time_out);
> 
>         Is this the one greater than the number of discriptors in the
> three select lists, or one greater than the largest value returned by
> any function that assigns a handle in the ??
> (stack/module/program/activation group). Or is there some other
> definition I am missing here ??
> 
>         Thanks,
>         Jeff Silberberg
> +---
> | This is the Midrange System Mailing List!
> | To submit a new message, send your mail to "MIDRANGE-L@midrange.com".
> | To unsubscribe from this list send email to MAJORDOMO@midrange.com
> |    and specify 'unsubscribe MIDRANGE-L' in the body of your message.
> | Questions should be directed to the list owner/operator: david@midrange.com
> +---
+---
| This is the Midrange System Mailing List!
| To submit a new message, send your mail to "MIDRANGE-L@midrange.com".
| To unsubscribe from this list send email to MAJORDOMO@midrange.com
|    and specify 'unsubscribe MIDRANGE-L' in the body of your message.
| Questions should be directed to the list owner/operator: david@midrange.com
+---


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.