[PATCH] s4/heimdal/lib/krb5/pac.c: typo

Jeremy Allison jra at samba.org
Wed Mar 9 19:36:52 UTC 2016


On Wed, Mar 09, 2016 at 04:51:17PM +0100, Aurélien Aptel wrote:
> Hi,
> 
> Another PVS fix.
> 
> The code was checking the wrong variable as malloc() result is stored
> in s2, not ucs2 which was already checked few lines earlier.
> 
> Please review&push.

LGTM - second Team reviewer please ?

> -- 
> Aurélien Aptel / SUSE Labs Samba Team
> GPG: 1839 CB5F 9F5B FB9B AA97  8C99 03C8 A49B 521B D5D3
> SUSE Linux GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
> GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG
> Nürnberg)

> From 097cdb739ca1333bca2fd8fe6eeebcf2f190b036 Mon Sep 17 00:00:00 2001
> From: Aurelien Aptel <aaptel at suse.com>
> Date: Wed, 9 Mar 2016 11:35:24 +0100
> Subject: [PATCH] s4/heimdal/lib/krb5/pac.c: typo
> 
> Signed-off-by: Aurelien Aptel <aaptel at suse.com>
> ---
>  source4/heimdal/lib/krb5/pac.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/source4/heimdal/lib/krb5/pac.c b/source4/heimdal/lib/krb5/pac.c
> index 7c8ba50..19663d2 100644
> --- a/source4/heimdal/lib/krb5/pac.c
> +++ b/source4/heimdal/lib/krb5/pac.c
> @@ -764,7 +764,7 @@ build_logon_name(krb5_context context,
>  
>  	s2_len = (ucs2_len + 1) * 2;
>  	s2 = malloc(s2_len);
> -	if (ucs2 == NULL) {
> +	if (s2 == NULL) {
>  	    free(ucs2);
>  	    return krb5_enomem(context);
>  	}
> -- 
> 2.1.4
> 






More information about the samba-technical mailing list