[vlc-commits] messages: split initial spamming to separate function
Rémi Denis-Courmont
git at videolan.org
Wed Feb 27 18:03:06 CET 2019
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Wed Feb 27 18:45:47 2019 +0200| [cf3aa22f0111742bb99838f692cb2201a0f94dde] | committer: Rémi Denis-Courmont
messages: split initial spamming to separate function
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=cf3aa22f0111742bb99838f692cb2201a0f94dde
---
src/misc/messages.c | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/src/misc/messages.c b/src/misc/messages.c
index 31e5b3aaaa..58b45cfd8c 100644
--- a/src/misc/messages.c
+++ b/src/misc/messages.c
@@ -42,6 +42,15 @@
#include <vlc_modules.h>
#include "../libvlc.h"
+static void vlc_LogSpam(vlc_object_t *obj)
+{
+ /* Announce who we are */
+ msg_Dbg(obj, "VLC media player - %s", VERSION_MESSAGE);
+ msg_Dbg(obj, "%s", COPYRIGHT_MESSAGE);
+ msg_Dbg(obj, "revision %s", psz_vlc_changeset);
+ msg_Dbg(obj, "configured with %s", CONFIGURE_LINE);
+}
+
struct vlc_logger {
const struct vlc_logger_operations *ops;
void *sys;
@@ -571,12 +580,7 @@ void vlc_LogSet(libvlc_int_t *vlc, const struct vlc_logger_operations *ops,
logger = &discard_log;
vlc_LogSwitch(vlc->obj.logger, logger);
-
- /* Announce who we are */
- msg_Dbg (vlc, "VLC media player - %s", VERSION_MESSAGE);
- msg_Dbg (vlc, "%s", COPYRIGHT_MESSAGE);
- msg_Dbg (vlc, "revision %s", psz_vlc_changeset);
- msg_Dbg (vlc, "configured with %s", CONFIGURE_LINE);
+ vlc_LogSpam(VLC_OBJECT(vlc));
}
void vlc_LogDestroy(vlc_logger_t *logger)
More information about the vlc-commits
mailing list