Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Marijn Suijten
pulseaudio
Commits
18193e4f
Commit
18193e4f
authored
May 10, 2020
by
pali
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bluetooth: Fix order when checking sender of hsphfpd dbus message
parent
76105b07
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
src/modules/bluetooth/hsphfpd-util.c
src/modules/bluetooth/hsphfpd-util.c
+9
-9
No files found.
src/modules/bluetooth/hsphfpd-util.c
View file @
18193e4f
...
...
@@ -234,11 +234,6 @@ static void hsphfpd_transport_connect_audio_reply(DBusPendingCall *pending, void
dbus_error_init
(
&
error
);
if
(
!
pa_safe_streq
(
dbus_message_get_sender
(
r
),
hsphfpd
->
hsphfpd_service_id
))
{
pa_log_error
(
"Reply for "
HSPHFPD_ENDPOINT_INTERFACE
".ConnectAudio() from invalid sender"
);
goto
failed
;
}
if
(
dbus_message_get_type
(
r
)
==
DBUS_MESSAGE_TYPE_ERROR
)
{
error_name
=
dbus_message_get_error_name
(
r
);
if
(
pa_safe_streq
(
error_name
,
HSPHFPD_SERVICE
".AlreadyConnected"
))
...
...
@@ -249,6 +244,11 @@ static void hsphfpd_transport_connect_audio_reply(DBusPendingCall *pending, void
goto
failed
;
}
if
(
!
pa_safe_streq
(
dbus_message_get_sender
(
r
),
hsphfpd
->
hsphfpd_service_id
))
{
pa_log_error
(
"Reply for "
HSPHFPD_ENDPOINT_INTERFACE
".ConnectAudio() from invalid sender"
);
goto
failed
;
}
if
(
!
pa_streq
(
dbus_message_get_signature
(
r
),
"oso"
))
{
pa_log_error
(
"Invalid reply signature for "
HSPHFPD_ENDPOINT_INTERFACE
".ConnectAudio()"
);
goto
failed
;
...
...
@@ -720,13 +720,13 @@ static void hsphfpd_get_endpoints_reply(DBusPendingCall *pending, void *userdata
goto
finish
;
}
if
(
!
dbus_mes
sa
g
e_
iter_init
(
r
,
&
arg_i
)
||
!
pa_streq
(
dbus_message_get_signature
(
r
),
"a{oa{sa{sv}}}"
))
{
pa_log_error
(
"
Invalid reply signature
for GetManagedObjects()"
);
if
(
!
pa_
sa
f
e_
streq
(
dbus_message_get_sender
(
r
),
hsphfpd
->
hsphfpd_service_id
))
{
pa_log_error
(
"
Reply
for GetManagedObjects()
from invalid sender
"
);
goto
finish
;
}
if
(
!
pa_safe_streq
(
dbus_message_get_sender
(
r
),
hsphfpd
->
hsphfpd_service_id
))
{
pa_log_error
(
"
Reply
for GetManagedObjects()
from invalid sender
"
);
if
(
!
dbus_message_iter_init
(
r
,
&
arg_i
)
||
!
pa_streq
(
dbus_message_get_signature
(
r
),
"a{oa{sa{sv}}}"
))
{
pa_log_error
(
"
Invalid reply signature
for GetManagedObjects()"
);
goto
finish
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment