summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Gundersen <teg@jklm.no>2015-07-14 21:14:45 +0200
committerTom Gundersen <teg@jklm.no>2015-07-14 21:14:45 +0200
commit2a2953b35505fb7f603b490c72edd76bd6469540 (patch)
tree2c1ab0693008f486e89e60f7a1471a9af8702d75
parentdad8f7f2b6eb34bead17df9b3966da9c4b4d79db (diff)
basic: util - fix memleak on error in unbase64mem()
-rw-r--r--src/basic/util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/basic/util.c b/src/basic/util.c
index bc917ae574..a45f5f8e53 100644
--- a/src/basic/util.c
+++ b/src/basic/util.c
@@ -1030,9 +1030,9 @@ char *base64mem(const void *p, size_t l) {
}
int unbase64mem(const char *p, size_t l, void **mem, size_t *_len) {
- _cleanup_free_ uint8_t *t = NULL;
+ _cleanup_free_ uint8_t *r = NULL;
int a, b, c, d;
- uint8_t *r, *z;
+ uint8_t *z;
const char *x;
size_t len;