build-aux: fix warning in the built _get_string() methods with -Wsign-compare
mm-enums-types.c: In function ‘mm_modem_lock_get_string’: mm-enums-types.c:165:17: warning: comparison of integer expressions of different signedness: ‘MMModemLock’ {aka ‘enum <anonymous>’} and ‘gint’ {aka ‘const int’} [-Wsign-compare] 165 | if (val == mm_modem_lock_values[i].value) | ^~
This commit is contained in:
@@ -51,7 +51,7 @@ const gchar *
|
||||
guint i;
|
||||
|
||||
for (i = 0; @enum_name@_values[i].value_nick; i++) {
|
||||
if (val == @enum_name@_values[i].value)
|
||||
if ((gint)val == @enum_name@_values[i].value)
|
||||
return @enum_name@_values[i].value_nick;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user