summaryrefslogtreecommitdiff
path: root/libnm
diff options
context:
space:
mode:
authorBeniamino Galvani <bgalvani@redhat.com>2018-07-04 13:56:25 +0200
committerBeniamino Galvani <bgalvani@redhat.com>2018-07-04 14:01:53 +0200
commitf3968264662b056722c721e5351a59f354f410e4 (patch)
tree13ec931ef9fe3586c081f6af9e986cb9fd717f4f /libnm
parent2ee76c88c10c109d7607501033097a0a762f9687 (diff)
downloadNetworkManager-f3968264662b056722c721e5351a59f354f410e4.tar.gz
libnm: add (allow-none) annotations to nm_device_reapply()
The @connection argument can be NULL; add the (allow-none) annotation otherwise calling the API with a NULL argument through GObject introspection fails with: Argument 1 does not allow None as a value Fixes: 278fd4fb0fde3f290e366dab91fb6a49f9ff186c
Diffstat (limited to 'libnm')
-rw-r--r--libnm/nm-device.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/libnm/nm-device.c b/libnm/nm-device.c
index 8c594d28b1..4745591553 100644
--- a/libnm/nm-device.c
+++ b/libnm/nm-device.c
@@ -1913,10 +1913,11 @@ nm_device_is_software (NMDevice *device)
/**
* nm_device_reapply:
* @device: a #NMDevice
- * @connection: the #NMConnection to replace the applied settings with or %NULL to reuse existing
- * @version_id: zero or the expected version id of the applied connection. If specified
- * and the version id mismatches, the call fails without modification. This allows to
- * catch concurrent accesses.
+ * @connection: (allow-none): the #NMConnection to replace the applied
+ * settings with or %NULL to reuse existing
+ * @version_id: zero or the expected version id of the applied connection.
+ * If specified and the version id mismatches, the call fails without
+ * modification. This allows to catch concurrent accesses.
* @flags: always set this to zero
* @cancellable: a #GCancellable, or %NULL
* @error: location for a #GError, or %NULL
@@ -1975,10 +1976,12 @@ device_reapply_cb (GObject *proxy,
/**
* nm_device_reapply_async:
* @device: a #NMDevice
- * @connection: the #NMConnection to replace the applied settings with or %NULL to reuse existing
- * @version_id: zero or the expected version id of the applied connection. If specified
- * and the version id mismatches, the call fails without modification. This allows to
- * catch concurrent accesses.
+ * @connection: (allow-none): the #NMConnection to replace the applied
+ * settings with or %NULL to reuse existing
+ * @version_id: zero or the expected version id of the applied
+ * connection. If specified and the version id mismatches, the call
+ * fails without modification. This allows to catch concurrent
+ * accesses.
* @flags: always set this to zero
* @cancellable: a #GCancellable, or %NULL
* @callback: callback to be called when the reapply operation completes