[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: fds_bits



On Thu, Sep 16, 1999 at 09:06:09PM -0400, Raul Miller wrote:
> On Fri, Sep 17, 1999 at 04:34:44AM +0800, Paul Harris wrote:
> > compiler error: 
> > vrweb-1.5/src/common/Dispatch/fdmask.C:99: `fds_bits' undeclared (first
> > use this function)
> > 
> > problem code:
> > 	if (fds_bits[i]) {
> > 
> > declaration in sys/types.h: 
> > /usr/include/bits/types.h:  __fd_mask fds_bits[__FD_SETSIZE / __NFDBITS];
> > (there are a few other references, but i think this is the key one)
> > 
> > does anyone know what i'm supposed to do with this fds_bits thing?
> 
> The excerpt from bits/types.h is part of the typedef struct __fd_set.
> The code from your fdmask.C looks like an actual variable reference.
> 
> I'm not sure why you have a reference to an undefined variable.  I just
> know that types.h isn't going to be declaring that variable for you.

The way I have overcome this with glibc 2.1 is to use __fds_bits or add
"#define __USE_XOPEN 1" to your source at the top.

Ben


Reply to: