From: Sebastian Harl Date: Tue, 22 Apr 2014 18:27:44 +0000 (+0200) Subject: frontend: Free strdup()'ed username when destroying a connection. X-Git-Tag: sysdb-0.1.0~98 X-Git-Url: https://git.tokkee.org/?p=sysdb.git;a=commitdiff_plain;h=95151b82610bd542d27b5372503f9afffaccd859 frontend: Free strdup()'ed username when destroying a connection. --- diff --git a/src/frontend/connection.c b/src/frontend/connection.c index 93829ab..aa03255 100644 --- a/src/frontend/connection.c +++ b/src/frontend/connection.c @@ -145,6 +145,10 @@ connection_destroy(sdb_object_t *obj) close(conn->fd); conn->fd = -1; + if (conn->username) + free(conn->username); + conn->username = NULL; + sdb_strbuf_destroy(conn->buf); conn->buf = NULL; sdb_strbuf_destroy(conn->errbuf);