kvspb / nginx-auth-ldap

LDAP authentication module for nginx
BSD 2-Clause "Simplified" License
731 stars 251 forks source link

Update ngx_http_auth_ldap_module.c - Initialize variable before use. #109

Closed rascal-hats closed 8 years ago

rascal-hats commented 8 years ago

Initialize count on line 806. Prevents compilation errors.

nginx-auth-ldap/ngx_http_auth_ldap_module.c:815:26: error: variable 'count' may be uninitialized when used here [-Werror,-Wconditional-uninitialized]
    cache->num_buckets = count;
                         ^~~~~
nginx-auth-ldap/ngx_http_auth_ldap_module.c:793:27: note: initialize the variable 'count' to silence this warning
    ngx_uint_t want, count, i;
                          ^
                           = 0