[MPlayer-dev-eng] [PATCH] Fix segmentation fault when pressing U (stop playing) in GUI
Ingo Brückl
ib at wupperonline.de
Mon Jun 6 16:31:43 CEST 2011
Reimar Döffinger wrote on Mon, 6 Jun 2011 15:02:21 +0200:
> More robust code would be for the condition that causes
> the crash and return "not available" or whatever the
> appropriate return value is.
I'm not sure that I get the point.
Unfortunately, the GUI doesn't use the MPlayer playtree, but an own one. So
everthing the MPlayer tries to make with the playtree will fail if the GUI
is involved. There are already some CONFIG_GUIs in order to take this into
account, but in case of MP_CMD_STOP it was missing.
>> +#ifdef CONFIG_GUI
>> + // playtree_iter isn't used by the GUI
>> + if (!use_gui)
>> +#endif
>> play_tree_iter_free(mpctx->playtree_iter);
> And here I guess play_tree_iter_free simply should support NULL.
Well, I didn't dare replacing the assert(), but here you go.
Ingo
-------------- next part --------------
A non-text attachment was scrubbed...
Name: U2.patch
Type: text/x-diff
Size: 1560 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20110606/0b49bc87/attachment.bin>
More information about the MPlayer-dev-eng
mailing list