]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
nwfilter: Move error messages onto a single line
authorMichal Privoznik <mprivozn@redhat.com>
Thu, 24 Aug 2023 15:03:58 +0000 (17:03 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Mon, 4 Sep 2023 07:35:36 +0000 (09:35 +0200)
Error messages are exempt from the 80 columns rule. Move them
onto one line.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
src/nwfilter/nwfilter_dhcpsnoop.c
src/nwfilter/nwfilter_learnipaddr.c

index 2f899238562f5fcc7c5719e976ad2c53e59322e9..26072ec26e16d61b35f8c740532cf61872b1d9f6 100644 (file)
@@ -1441,9 +1441,7 @@ virNWFilterDHCPSnoopReq(virNWFilterTechDriver *techdriver,
     /* check that all tools are available for applying the filters (late) */
     if (!techdriver->canApplyBasicRules()) {
         virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
-                       _("IP parameter must be provided since "
-                         "snooping the IP address does not work "
-                         "possibly due to missing tools"));
+                       _("IP parameter must be provided since snooping the IP address does not work possibly due to missing tools"));
         goto exit_snoopreqput;
     }
 
@@ -1454,8 +1452,7 @@ virNWFilterDHCPSnoopReq(virNWFilterTechDriver *techdriver,
                                        &req->binding->mac,
                                        dhcpsrvrs, false) < 0) {
         virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
-                       _("applyDHCPOnlyRules "
-                         "failed - spoofing not protected!"));
+                       _("applyDHCPOnlyRules failed - spoofing not protected!"));
         goto exit_snoopreqput;
     }
 
@@ -1990,9 +1987,8 @@ virNWFilterDHCPSnoopReq(virNWFilterTechDriver *techdriver G_GNUC_UNUSED,
                         virNWFilterDriverState *driver G_GNUC_UNUSED)
 {
     virReportError(VIR_ERR_INTERNAL_ERROR,
-                   _("libvirt was not compiled with libpcap and \""
-                     NWFILTER_VARNAME_CTRL_IP_LEARNING
-                     "='dhcp'\" requires it."));
+                   _("libvirt was not compiled with libpcap and \"%1$s\" requires it"),
+                     NWFILTER_VARNAME_CTRL_IP_LEARNING "='dhcp'");
     return -1;
 }
 #endif /* WITH_LIBPCAP */
index 90e9a21a4eaadbfa39fecf58e05f1a38f41ad56e..73d8302c13a19ecbe94298955533fd0a51189de2 100644 (file)
@@ -669,9 +669,7 @@ virNWFilterLearnIPAddress(virNWFilterTechDriver *techdriver,
 
     if (!techdriver->canApplyBasicRules()) {
         virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
-                       _("IP parameter must be provided since "
-                         "snooping the IP address does not work "
-                         "possibly due to missing tools"));
+                       _("IP parameter must be provided since snooping the IP address does not work possibly due to missing tools"));
         return -1;
     }
 
@@ -717,9 +715,7 @@ virNWFilterLearnIPAddress(virNWFilterTechDriver *techdriver G_GNUC_UNUSED,
                           int howDetect G_GNUC_UNUSED)
 {
     virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
-                   _("IP parameter must be given since libvirt "
-                     "was not compiled with IP address learning "
-                     "support"));
+                   _("IP parameter must be given since libvirt was not compiled with IP address learning support"));
     return -1;
 }
 #endif /* WITH_LIBPCAP */