]> xenbits.xensource.com Git - libvirt.git/commitdiff
virfirewalld: Drop useless memset() in virFirewallDApplyRule()
authorMichal Privoznik <mprivozn@redhat.com>
Thu, 3 Aug 2023 08:30:12 +0000 (10:30 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Thu, 3 Aug 2023 14:35:58 +0000 (16:35 +0200)
This is a residue of v6.8.0-rc1~100. The error variable inside of
virFirewallDApplyRule() is already initialized to NULL. There's
no need to memset() it to zero again.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Claudio Fontana <cfontana@suse.de>
src/util/virfirewalld.c

index 6fc54f357d961af182c06e826355535867ab3146..827e201dbbe1be361e7e3158081cba617ef30716 100644 (file)
@@ -360,8 +360,6 @@ virFirewallDApplyRule(virFirewallLayer layer,
     if (!sysbus)
         return -1;
 
-    memset(&error, 0, sizeof(error));
-
     if (!ipv) {
         virReportError(VIR_ERR_INTERNAL_ERROR,
                        _("Unknown firewall layer %1$d"),