summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2005-11-12 18:47:43 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2005-11-12 18:47:43 +0000
commit8c5b9b2a28ebd56052885f36227c81cd89471f07 (patch)
treeea0fd79377969040b14887b03b3366923d83afbb
parent9ce2494873e129ad7474b1679a46b155bf3059c8 (diff)
left a free() behind, spotted by cloder
-rw-r--r--sbin/ccdconfig/ccdconfig.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sbin/ccdconfig/ccdconfig.c b/sbin/ccdconfig/ccdconfig.c
index 01b64936dbb..a6ca72d91ef 100644
--- a/sbin/ccdconfig/ccdconfig.c
+++ b/sbin/ccdconfig/ccdconfig.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ccdconfig.c,v 1.24 2005/11/12 15:26:23 deraadt Exp $ */
+/* $OpenBSD: ccdconfig.c,v 1.25 2005/11/12 18:47:42 deraadt Exp $ */
/* $NetBSD: ccdconfig.c,v 1.6 1996/05/16 07:11:18 thorpej Exp $ */
/*-
@@ -434,10 +434,8 @@ resolve_ccdname(char *name)
c = name[len - 1];
if (isdigit(c)) {
- if ((rawpart = getrawpartition()) < 0) {
- free(path);
+ if ((rawpart = getrawpartition()) < 0)
return (NULL);
- }
if (asprintf(&path, "/dev/%s%c", name, 'a' + rawpart) == -1)
return (NULL);
} else {