[PATCH] rpcrt4: fixed memory leak on error exit (Coverity)

Dmitry Timoshkov dmitry at baikal.ru
Tue Jul 15 02:13:36 CDT 2014


Marcus Meissner <marcus at jet.franken.de> wrote:

> --- a/dlls/rpcrt4/rpc_transport.c
> +++ b/dlls/rpcrt4/rpc_transport.c
> @@ -941,6 +941,7 @@ static size_t rpcrt4_ip_tcp_get_top_of_tower(unsigned char *tower_data,
>      }
>      else
>      {
> +        freeaddrinfo(ai);
>          ERR("unexpected protocol family %d\n", ai->ai_family);
>          return 0;
>      }

This will introduce use after free (by ERR() statement).

-- 
Dmitry.



More information about the wine-devel mailing list