On Fri, Aug 24, 2012 at 12:44:53AM +0200, [email protected] wrote:
> From: Pablo Neira Ayuso <[email protected]>

> @@ -592,15 +634,25 @@ static int ipaccess_bsc_oml_cb(struct ipa_server_link 
> *link, int fd)
>       ret = osmo_fd_register(bfd);
>       if (ret < 0) {
>               LOGP(DLINP, LOGL_ERROR, "could not register FD\n");
> -             close(bfd->fd);
> -             e1inp_line_put(line);
> -             return ret;
> +             goto err_line;



> -        return ret;
> +err_socket:
> +     osmo_fd_unregister(bfd);
> +     close(bfd->fd);
> +     bfd->fd = -1;
> +err_line:
> +     e1inp_line_put(line);
> +     return ret;
>  }

in this case the socket was closed and remains open now? It needs to jump under 
the
osmo_fd_unregister line.


>       /* initialize the fds */
>       for (i = 0; i < ARRAY_SIZE(line->ts); ++i)
> @@ -636,14 +688,24 @@ static int ipaccess_bsc_rsl_cb(struct ipa_server_link 
> *link, int fd)
>       ret = osmo_fd_register(bfd);
>       if (ret < 0) {
>               LOGP(DLINP, LOGL_ERROR, "could not register FD\n");
> -             close(bfd->fd);
> -             e1inp_line_put(line);
> -             return ret;
> +             goto err_line;

same as above.


Reply via email to