[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: (ITS#4765) sd_actives in daemon.c not initialized?

Gang Wang wrote:
> Yes. but funny that you invoked FD_ZERO() for sd_readers and sd_writers. 
> You are assuming the semantics of FD_ZERO() is to "set something as 
> zero", but on some system it is not. For example, implement fd_set as an 
> array, then 0 is a valid value. FD_ZERO() have to initialize something 
> as -1 ...
> Funny that the code treat sd_actives differently.

Thanks for pointing this out, the missing initialization has been added 

   -- Howard Chu
   Chief Architect, Symas Corp.  http://www.symas.com
   Director, Highland Sun        http://highlandsun.com/hyc
   OpenLDAP Core Team            http://www.openldap.org/project/