From 716f7a09c0067be4275b6094fe5e38510c0e8317 Mon Sep 17 00:00:00 2001 From: Petri Hintukainen Date: Wed, 30 Apr 2014 15:28:35 +0300 Subject: video_oput_fb: add error logging --- src/video_out/video_out_fb.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/video_out/video_out_fb.c b/src/video_out/video_out_fb.c index 346a4d31d..bba1e0b8b 100644 --- a/src/video_out/video_out_fb.c +++ b/src/video_out/video_out_fb.c @@ -973,12 +973,19 @@ static vo_driver_t *fb_open_plugin(video_driver_class_t *class_gen, this->fd = open_fb_device(config, class->xine); if(this->fd == -1) goto error; - if(!get_fb_var_screeninfo(this->fd, &this->fb_var, class->xine)) + if(!get_fb_var_screeninfo(this->fd, &this->fb_var, class->xine)) { + xprintf(this->xine, XINE_VERBOSITY_LOG, "video_out_fb: get_fb_var_screeninfo() failed: %s\n", strerror(errno)); goto error; - if(!get_fb_fix_screeninfo(this->fd, &this->fb_fix, class->xine)) + } + if(!get_fb_fix_screeninfo(this->fd, &this->fb_fix, class->xine)) { + xprintf(this->xine, XINE_VERBOSITY_LOG, "video_out_fb: get_fb_fix_screeninfo() failed: %s\n", strerror(errno)); goto error; - if (!set_fb_palette (this->fd, &this->fb_var)) + } + + if (!set_fb_palette (this->fd, &this->fb_var)) { + xprintf(this->xine, XINE_VERBOSITY_LOG, "video_out_fb: set_fb_palette() failed: %s\n", strerror(errno)); goto error; + } this->xine = class->xine; @@ -1024,6 +1031,9 @@ static vo_driver_t *fb_open_plugin(video_driver_class_t *class_gen, MAP_SHARED, this->fd, 0); return &this->vo_driver; error: + xprintf(class->xine, XINE_VERBOSITY_DEBUG, + "video_out_fb: Unable to configure fb device, aborting: %s\n", strerror(errno)); + free(this); return 0; } -- cgit v1.2.3