Fixed memory leak in getUsers bug 439

Fixed memory leak in getUsers bug 439
This commit is contained in:
MassimilianoPinto
2014-09-15 15:53:09 +02:00
parent 7225804c42
commit 4e88833d3e

View File

@ -359,10 +359,10 @@ getUsers(SERVICE *service, struct users *users)
row[0], row[0],
row[1], row[1],
rc == NULL ? "NULL" : ret_ip))); rc == NULL ? "NULL" : ret_ip)));
continue;
} }
free(key.user);
} else { } else {
/* setipaddress() failed, skip user add and log this*/ /* setipaddress() failed, skip user add and log this*/
LOGIF(LE, (skygw_log_write_flush( LOGIF(LE, (skygw_log_write_flush(
@ -380,7 +380,6 @@ getUsers(SERVICE *service, struct users *users)
memcpy(users->cksum, hash, SHA_DIGEST_LENGTH); memcpy(users->cksum, hash, SHA_DIGEST_LENGTH);
free(users_data); free(users_data);
free(key.user);
mysql_free_result(result); mysql_free_result(result);
mysql_close(con); mysql_close(con);