Fix cursor_mode checks in screencast.c

This commit is contained in:
columbarius 2020-11-06 13:11:47 +01:00 committed by Simon Ser
parent 24bc68f0f2
commit f0e1de02f4

View file

@ -245,10 +245,10 @@ static int method_screencast_select_sources(sd_bus_message *msg, void *data,
} else if (strcmp(key, "cursor_mode") == 0) { } else if (strcmp(key, "cursor_mode") == 0) {
uint32_t cursor_mode; uint32_t cursor_mode;
sd_bus_message_read(msg, "v", "u", &cursor_mode); sd_bus_message_read(msg, "v", "u", &cursor_mode);
if (cursor_mode & (1<<HIDDEN)) { if (cursor_mode & HIDDEN) {
cursor_embedded = false; cursor_embedded = false;
} }
if (cursor_mode & (1<<METADATA)) { if (cursor_mode & METADATA) {
logprint(ERROR, "dbus: unsupported cursor mode requested, cancelling"); logprint(ERROR, "dbus: unsupported cursor mode requested, cancelling");
goto error; goto error;
} }