backends/native: Protect against NULL pointer constraint
To clear a pointer constraint, the Wayland backend passes a NULL constraint to the native input backend.
The new async API however tries to reference/un-reference the given object to use it while running in a separate task, which leads to a warning from GLib trying to g_object_ref()/g_object_unref() a non GObject pointer.
To avoid that issue, use a dedicated helper which will check for the given pointer to be non-NULL prior to trying to use GObject reference counting on it.
Closes: #1587 (closed)
Edited by Olivier Fourdan