[PATCH libosinfo 4/4] maint.mk: Adjust sc_prohibit_strcmp

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



- There's no need to exclude STRN?EQ as those are not defined in
libosinfo;
- Adjust the comment and the halt message to suggest the usage of
g_str_equal() instead of the non existent STRN?EQ();

https://bugzilla.redhat.com/show_bug.cgi?id=1335291

Signed-off-by: Fabiano Fidêncio <fidencio@xxxxxxxxxx>
---
 maint.mk | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/maint.mk b/maint.mk
index 04a839a..ccf874c 100644
--- a/maint.mk
+++ b/maint.mk
@@ -350,12 +350,11 @@ sc_prohibit_atoi_atof:
 	halt='do not use *scan''f, ato''f, ato''i, ato''l, ato''ll or ato''q'	\
 	  $(_sc_search_regexp)
 
-# Use STREQ rather than comparing strcmp == 0, or != 0.
+# Use g_str_equal() rather than comparing strcmp == 0, or != 0.
 sp_ = strcmp *\(.+\)
 sc_prohibit_strcmp:
 	@prohibit='! *strcmp *\(|\<$(sp_) *[!=]=|[!=]= *$(sp_)'		\
-	exclude='# *define STRN?EQ\('					\
-	halt='replace strcmp calls above with STREQ/STRNEQ'		\
+	halt='replace strcmp calls above with g_str_equal()'		\
 	  $(_sc_search_regexp)
 
 # Really.  You don't want to use this function.
-- 
2.17.1

_______________________________________________
Libosinfo mailing list
Libosinfo@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libosinfo




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux