[MPlayer-dev-eng] Fwd: Re: [MPlayer-users] mplayer cvs -vo fbdev crashing since revision
Arpi
arpi at thot.banki.hu
Wed Jan 8 19:00:45 CET 2003
someone fix that broken -geometry shit ASAP or i'll reverse the whole
commit
--------- Forwarded message ---------
From: Felix von Leitner <leitner at convergence.de>
To: mplayer-users at mplayerhq.hu
Subject: Re: [MPlayer-users] mplayer cvs -vo fbdev crashing since revision
[Automatic answer: RTFM (read DOCS, FAQ), also read DOCS/bugreports.html]
Thus spake Felix von Leitner (leitner at convergence.de):
> A few days ago, mplayer -vo fbdev stopped working.
> I was always using fbdev=nocopy, but removing the nocopy didn't help.
> A look at the CVS log reveals that the last change was at 2003/01/03,
> which matches the time my troubles started.
> gdb says that crash is in fast_memcpy_MMX2.
I looked a little closer.
The crash is the memcpy around line 1235 in libvo/vo_fbdev.c:
(gdb) p L123123875
$1 = (uint8_t *) 0xc11df710 <Address 0xc11df710 out of bounds>
(gdb) n
1239 in_width * fb_pixel_size);
(gdb) n
Program received signal SIGSEGV, Segmentation fault.
fast_memcpy_MMX2 (to=0xc11df710, from=0x450c4008, len=1104) at
aclib_template.c:173
173 small_memcpy(to, from, delta);
(my lines are a little off because I had to insert a function to be able
to set a breakpoint easily). Mhh, what an intuitive variable name ;)
Apparently it is used to implement double buffering in the frame buffer.
The value is not clobbered later but it is assigned this preposterous
value in the vo_fbdev.c initialization right after the geometry call.
1075 L123123875 = frame_buffer + (out_width - in_width) *
fb_pixel_size /
1076 2 + ( (out_height - in_height) / 2 ) *
fb_line_len +
1077 x_offset * fb_pixel_size + y_offset * fb_line_len;
The reason appears to be that x_offset is uninitialized
(gdb) p x_offset
$9 = -1073751144
geometry is obviously meant to write some value there, but doesn't. I
just set it to 0 and now I get a picture, but it starts in the lower 4/5
of the screen, only partially visible. I vote to rip out that geometry
stuff and just set x_offset and y_offset to 0. I just did that and now
vo_fbdev works again.
Felix
_______________________________________________
RTFM!!! http://www.MPlayerHQ.hu/DOCS
Search: http://www.MPlayerHQ.hu/cgi-bin/htsearch
http://mplayerhq.hu/mailman/listinfo/mplayer-users
More information about the MPlayer-dev-eng
mailing list