Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
a666d9b2
Commit
a666d9b2
authored
Aug 08, 2012
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PulseAudio: log context events
parent
8f95eae9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
1 deletion
+13
-1
modules/audio_output/pulse.c
modules/audio_output/pulse.c
+1
-1
modules/audio_output/vlcpulse.c
modules/audio_output/vlcpulse.c
+12
-0
No files found.
modules/audio_output/pulse.c
View file @
a666d9b2
...
...
@@ -382,7 +382,7 @@ static void stream_event_cb(pa_stream *s, const char *name, pa_proplist *pl,
dummy
,
dummy
,
NULL
);
}
else
#endif
msg_Warn
(
aout
,
"unhandled
event %s
"
,
name
);
msg_Warn
(
aout
,
"unhandled
stream event
\"
%s
\"
"
,
name
);
(
void
)
s
;
(
void
)
pl
;
}
...
...
modules/audio_output/vlcpulse.c
View file @
a666d9b2
...
...
@@ -68,6 +68,16 @@ static bool context_wait (pa_context *ctx, pa_threaded_mainloop *mainloop)
return
0
;
}
static
void
context_event_cb
(
pa_context
*
c
,
const
char
*
name
,
pa_proplist
*
pl
,
void
*
userdata
)
{
vlc_object_t
*
obj
=
userdata
;
msg_Warn
(
obj
,
"unhandled context event
\"
%s
\"
"
,
name
);
(
void
)
c
;
(
void
)
pl
;
}
/**
* Initializes the PulseAudio main loop and connects to the PulseAudio server.
* @return a PulseAudio context on success, or NULL on error
...
...
@@ -144,6 +154,7 @@ pa_context *vlc_pa_connect (vlc_object_t *obj, pa_threaded_mainloop **mlp)
goto
fail
;
pa_context_set_state_callback
(
ctx
,
context_state_cb
,
mainloop
);
pa_context_set_event_callback
(
ctx
,
context_event_cb
,
obj
);
if
(
pa_context_connect
(
ctx
,
NULL
,
0
,
NULL
)
<
0
||
context_wait
(
ctx
,
mainloop
))
{
...
...
@@ -177,6 +188,7 @@ void vlc_pa_disconnect (vlc_object_t *obj, pa_context *ctx,
{
pa_threaded_mainloop_lock
(
mainloop
);
pa_context_disconnect
(
ctx
);
pa_context_set_event_callback
(
ctx
,
NULL
,
NULL
);
pa_context_set_state_callback
(
ctx
,
NULL
,
NULL
);
pa_context_unref
(
ctx
);
pa_threaded_mainloop_unlock
(
mainloop
);
...
...
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