Removed internal checks.

This commit is contained in:
Armin Novak 2019-01-22 10:50:34 +01:00
parent 9eb897ea6b
commit 68b5d47d9a
1 changed files with 2 additions and 9 deletions

View File

@ -126,13 +126,9 @@ static const struct wl_data_source_listener data_source_listener =
.cancelled = data_source_cancelled_handler
};
static UwacReturnCode UwacRegisterDeviceListener(UwacSeat* s)
static void UwacRegisterDeviceListener(UwacSeat* s)
{
if (!s)
return UWAC_ERROR_INTERNAL;
wl_data_device_add_listener(s->data_device, &data_device_listener, s);
return UWAC_SUCCESS;
}
UwacReturnCode UwacCreateDataSource(UwacSeat* s)
@ -153,10 +149,7 @@ UwacReturnCode UwacSeatRegisterClipboard(UwacSeat* s)
if (!s)
return UWAC_ERROR_INTERNAL;
rc = UwacRegisterDeviceListener(s);
if (rc != UWAC_SUCCESS)
return rc;
UwacRegisterDeviceListener(s);
rc = UwacCreateDataSource(s);