[vlc-devel] [PATCH] input: log slave source creation failure
MANJEET YADUVANSHI
manjeetyaduvanshi250 at gmail.com
Sun Apr 19 23:39:24 UTC 2026
Hi,
This patch adds a log message when InputSourceNew() fails in
input_SlaveSourceAdd().
It uses the existing SLAVE_ADD_CANFAIL flag to differentiate between
optional and required slave sources, logging warnings for optional failures
and errors for required ones. This makes such failures visible while
keeping the behavior unchanged.
Thanks,
Manjeet Yaduvanshi
From: Manjeet Yaduvanshi <manjeetyaduvanshi250 at gmail.com>
Subject: [PATCH] input: log slave source creation failure
diff --git a/src/input/input.c b/src/input/input.c
--- a/src/input/input.c
+++ b/src/input/input.c
@@
input_source_t *p_source = InputSourceNew( psz_uri );
- if( !p_source )
- return VLC_EGENERIC;
+ if( !p_source )
+ {
+ if( b_can_fail )
+ msg_Warn( p_input, "could not create slave source for %s", psz_uri );
+ else
+ msg_Err( p_input, "could not create slave source for %s", psz_uri );
+
+ return VLC_EGENERIC;
+ }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20260420/b6da80ee/attachment.htm>
More information about the vlc-devel
mailing list