summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/import/pull-dkr.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/import/pull-dkr.c b/src/import/pull-dkr.c
index 38c8db9eb2..dd2097bb1d 100644
--- a/src/import/pull-dkr.c
+++ b/src/import/pull-dkr.c
@@ -1246,7 +1246,7 @@ finish:
static int get_protocol_address(char **protocol, char **address, const char *url) {
const char *sep, *dot;
- char *a, *p;
+ _cleanup_free_ char *a = NULL, *p = NULL;
sep = strstr(url, "://");
if (!sep)
@@ -1270,6 +1270,7 @@ static int get_protocol_address(char **protocol, char **address, const char *url
*address = a;
*protocol = p;
+ a = p = NULL;
return 0;
}