Skip to content

Commit

Permalink
notification: Always set error in the failure case
Browse files Browse the repository at this point in the history
  • Loading branch information
swick authored and GeorgesStavracas committed Nov 5, 2024
1 parent 4a2abe2 commit 6362361
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/notification.c
Original file line number Diff line number Diff line change
Expand Up @@ -806,7 +806,13 @@ parse_serialized_sound (GVariantBuilder *builder,
}

if (!xdp_validate_sound (sealed_sound))
return FALSE;
{
g_set_error_literal (error,
XDG_DESKTOP_PORTAL_ERROR,
XDG_DESKTOP_PORTAL_ERROR_INVALID_ARGUMENT,
"Invalid sound: The sound data is invalid");
return FALSE;
}

fd_sound = xdp_sealed_fd_to_handle (sealed_sound,
out_fd_list,
Expand Down

0 comments on commit 6362361

Please sign in to comment.