crypto/x509v3/v3_sxnet.c:126: error: MEMORY_LEAK
  memory dynamically allocated to `return` by call to `malloc()` at line 124, column 2 is not reachable after line 126, column 2.
Showing all 23 steps of the trace


crypto/x509v3/v3_sxnet.c:120:1: start of procedure SXNET_new()
118.   }
119.   
120. > SXNET *SXNET_new(void)
121.   {
122.   	SXNET *ret=NULL;

crypto/x509v3/v3_sxnet.c:122:2: 
120.   SXNET *SXNET_new(void)
121.   {
122. > 	SXNET *ret=NULL;
123.   	ASN1_CTX c;
124.   	M_ASN1_New_Malloc(ret, SXNET);

crypto/x509v3/v3_sxnet.c:124:2: Taking false branch
122.   	SXNET *ret=NULL;
123.   	ASN1_CTX c;
124.   	M_ASN1_New_Malloc(ret, SXNET);
        ^
125.   	M_ASN1_New(ret->version,ASN1_INTEGER_new);
126.   	M_ASN1_New(ret->ids,sk_SXNETID_new_null);

crypto/x509v3/v3_sxnet.c:125:2: 
123.   	ASN1_CTX c;
124.   	M_ASN1_New_Malloc(ret, SXNET);
125. > 	M_ASN1_New(ret->version,ASN1_INTEGER_new);
126.   	M_ASN1_New(ret->ids,sk_SXNETID_new_null);
127.   	return (ret);

crypto/asn1/asn1_lib.c:368:1: start of procedure ASN1_STRING_type_new()
  366.   
  367.   
  368. > ASN1_STRING *ASN1_STRING_type_new(int type)
  369.   	{
  370.   	ASN1_STRING *ret;

crypto/asn1/asn1_lib.c:372:2: 
  370.   	ASN1_STRING *ret;
  371.   
  372. > 	ret=(ASN1_STRING *)Malloc(sizeof(ASN1_STRING));
  373.   	if (ret == NULL)
  374.   		{

crypto/asn1/asn1_lib.c:373:6: Taking false branch
  371.   
  372.   	ret=(ASN1_STRING *)Malloc(sizeof(ASN1_STRING));
  373.   	if (ret == NULL)
              ^
  374.   		{
  375.   		ASN1err(ASN1_F_ASN1_STRING_TYPE_NEW,ERR_R_MALLOC_FAILURE);

crypto/asn1/asn1_lib.c:378:2: 
  376.   		return(NULL);
  377.   		}
  378. > 	ret->length=0;
  379.   	ret->type=type;
  380.   	ret->data=NULL;

crypto/asn1/asn1_lib.c:379:2: 
  377.   		}
  378.   	ret->length=0;
  379. > 	ret->type=type;
  380.   	ret->data=NULL;
  381.   	ret->flags=0;

crypto/asn1/asn1_lib.c:380:2: 
  378.   	ret->length=0;
  379.   	ret->type=type;
  380. > 	ret->data=NULL;
  381.   	ret->flags=0;
  382.   	return(ret);

crypto/asn1/asn1_lib.c:381:2: 
  379.   	ret->type=type;
  380.   	ret->data=NULL;
  381. > 	ret->flags=0;
  382.   	return(ret);
  383.   	}

crypto/asn1/asn1_lib.c:382:2: 
  380.   	ret->data=NULL;
  381.   	ret->flags=0;
  382. > 	return(ret);
  383.   	}
  384.   

crypto/asn1/asn1_lib.c:383:2: return from a call to ASN1_STRING_type_new
  381.   	ret->flags=0;
  382.   	return(ret);
  383.   	}
          ^
  384.   
  385.   void ASN1_STRING_free(ASN1_STRING *a)

crypto/x509v3/v3_sxnet.c:125:2: Taking false branch
123.   	ASN1_CTX c;
124.   	M_ASN1_New_Malloc(ret, SXNET);
125.   	M_ASN1_New(ret->version,ASN1_INTEGER_new);
        ^
126.   	M_ASN1_New(ret->ids,sk_SXNETID_new_null);
127.   	return (ret);

crypto/x509v3/v3_sxnet.c:126:2: 
124.   	M_ASN1_New_Malloc(ret, SXNET);
125.   	M_ASN1_New(ret->version,ASN1_INTEGER_new);
126. > 	M_ASN1_New(ret->ids,sk_SXNETID_new_null);
127.   	return (ret);
128.   	M_ASN1_New_Error(ASN1_F_SXNET_NEW);

crypto/x509v3/v3_sxnet.c:350:1: start of procedure sk_SXNETID_new_null()
  348.   }
  349.   
  350. > IMPLEMENT_STACK_OF(SXNETID)
  351.   IMPLEMENT_ASN1_SET_OF(SXNETID)

crypto/stack/stack.c:117:1: start of procedure sk_new()
    115.   	}
    116.   
    117. > STACK *sk_new(int (*c)())
    118.   	{
    119.   	STACK *ret;

crypto/stack/stack.c:122:6: Taking true branch
    120.   	int i;
    121.   
    122.   	if ((ret=(STACK *)Malloc(sizeof(STACK))) == NULL)
                ^
    123.   		goto err0;
    124.   	if ((ret->data=(char **)Malloc(sizeof(char *)*MIN_NODES)) == NULL)

crypto/stack/stack.c:135:1: 
    133.   err1:
    134.   	Free((char *)ret);
    135. > err0:
    136.   	return(NULL);
    137.   	}

crypto/stack/stack.c:136:2: 
    134.   	Free((char *)ret);
    135.   err0:
    136. > 	return(NULL);
    137.   	}
    138.   

crypto/stack/stack.c:137:2: return from a call to sk_new
    135.   err0:
    136.   	return(NULL);
    137.   	}
            ^
    138.   
    139.   int sk_insert(STACK *st, char *data, int loc)

crypto/x509v3/v3_sxnet.c:350:1: return from a call to sk_SXNETID_new_null
  348.   }
  349.   
  350. > IMPLEMENT_STACK_OF(SXNETID)
  351.   IMPLEMENT_ASN1_SET_OF(SXNETID)

crypto/x509v3/v3_sxnet.c:126:2: Taking true branch
124.   	M_ASN1_New_Malloc(ret, SXNET);
125.   	M_ASN1_New(ret->version,ASN1_INTEGER_new);
126.   	M_ASN1_New(ret->ids,sk_SXNETID_new_null);
        ^
127.   	return (ret);
128.   	M_ASN1_New_Error(ASN1_F_SXNET_NEW);
