Commit 64379de3 authored by Christophe Massiot's avatar Christophe Massiot

* en50221.c: Fix memory leak (thanks ivoire).

parent 06501568
......@@ -812,10 +812,8 @@ static int APDUSend( access_t * p_access, int i_session_id, int i_tag,
}
else
{
char *psz_hex;
ca_msg.length = i_size + p - p_apdu;
if ( i_size == 0 ) ca_msg.length=3;
psz_hex = (char*)malloc( ca_msg.length*3 + 1);
memcpy( ca_msg.msg, p_apdu, i_size + p - p_apdu );
i_ret = ioctl(i_ca_handle, CA_SEND_MSG, &ca_msg );
if ( i_ret < 0 )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment