]> xenbits.xensource.com Git - people/dariof/libvirt.git/commitdiff
selinux: remove unused variables in socket labelling
authorGuannan Ren <gren@redhat.com>
Wed, 17 Oct 2012 03:28:28 +0000 (11:28 +0800)
committerGuannan Ren <gren@redhat.com>
Wed, 17 Oct 2012 05:13:17 +0000 (13:13 +0800)
src/security/security_selinux.c

index 85419ba41dbad882de3ccb836e86f026b7f02522..b5108abb298d2023d6a373ced3200497ffda6bd4 100644 (file)
@@ -1634,8 +1634,6 @@ virSecuritySELinuxSetSecurityDaemonSocketLabel(virSecurityManagerPtr mgr,
 {
     /* TODO: verify DOI */
     virSecurityLabelDefPtr secdef;
-    context_t execcon = NULL;
-    context_t proccon = NULL;
     security_context_t scon = NULL;
     char *str = NULL;
     int rc = -1;
@@ -1678,8 +1676,6 @@ done:
 
     if (security_getenforce() != 1)
         rc = 0;
-    if (execcon) context_free(execcon);
-    if (proccon) context_free(proccon);
     freecon(scon);
     VIR_FREE(str);
     return rc;