Ignore:
Timestamp:
Jun 25, 2011, 7:14:41 PM (14 years ago)
Author:
Herwig Bauernfeind
Message:

Update Samba 3.3 to 3.3.15 (security update)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/samba-3.3.x/source/winbindd/winbindd.c

    r342 r578  
    837837        listen_priv_sock = open_winbindd_priv_socket();
    838838
    839         if (listen_sock == -1 || listen_priv_sock == -1) {
     839        if (listen_sock < 0 || listen_sock >= FD_SETSIZE ||
     840                        listen_priv_sock < 0 || listen_priv_sock >= FD_SETSIZE) {
    840841                perror("open_winbind_socket");
    841842                exit(1);
     
    862863        FD_ZERO(&r_fds);
    863864        FD_ZERO(&w_fds);
     865
     866        /* We check the range for listen_sock and
     867           listen_priv_sock above. */
    864868        FD_SET(listen_sock, &r_fds);
    865869        FD_SET(listen_priv_sock, &r_fds);
     
    891895
    892896        for (ev = fd_events; ev; ev = ev->next) {
     897                if (ev->fd < 0 || ev->fd >= FD_SETSIZE) {
     898                        /* Ignore here - event_add_to_select_args
     899                           should make this impossible. */
     900                        continue;
     901                }
     902
    893903                if (ev->flags & EVENT_FD_READ) {
    894904                        FD_SET(ev->fd, &r_fds);
Note: See TracChangeset for help on using the changeset viewer.