libnm: avoid deprecation warning about NMUtilsPredicateStr

NMUtilsPredicateStr got introduced in 1.26.0 API. However, marking the typedef
to be available only in 1.26, causes a compiler warning when using the header:

    /usr/include/libnm/nm-setting.h:372:39: error: ‘NMUtilsPredicateStr’ is deprecated: Not available before 1.26 [-Werror=deprecated-declarations]
      372 |                                       NMUtilsPredicateStr predicate);
          |                                       ^~~~~~~~~~~~~~~~~~~
    cc1: all warnings being treated as errors

Avoid that. It's not a problem in practice, because all users of the typedef
are functions that are marked to be available in 1.26 themselves.
This commit is contained in:
Thomas Haller 2020-06-22 13:22:40 +02:00
parent 62263e706f
commit 8a13b02d96
No known key found for this signature in database
GPG key ID: 29C2366E4DFC5728

View file

@ -65,7 +65,6 @@ typedef struct _NMSettingWirelessSecurity NMSettingWirelessSecurity;
typedef struct _NMSettingWpan NMSettingWpan;
typedef struct _NMSimpleConnection NMSimpleConnection;
NM_AVAILABLE_IN_1_26
typedef gboolean (*NMUtilsPredicateStr) (const char *str);
#endif /* __NM_CORE_TYPES_H__ */