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:
Aleksander Morgado
2019-11-19 11:36:08 +01:00
parent 1c078531a0
commit cf211c01e9

View File

@@ -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;
}