Mercurial > mplayer.hg
changeset 13101:e19b46309883
prevent XFree execution on wrong condition
author | iive |
---|---|
date | Mon, 23 Aug 2004 09:52:25 +0000 |
parents | 17e40e9b7654 |
children | a546629f3117 |
files | libvo/vo_xvmc.c |
diffstat | 1 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/libvo/vo_xvmc.c Mon Aug 23 08:03:31 2004 +0000 +++ b/libvo/vo_xvmc.c Mon Aug 23 09:52:25 2004 +0000 @@ -207,8 +207,8 @@ if(keycolor_handling == AUTO_COLORKEY){ //XV_AUTOPING_COLORKEY doesn't work for XvMC yet(NVidia 43.63) attributes = XvQueryPortAttributes(mDisplay, xv_port, &attrib_count); - if(attributes!=NULL) - for (i = 0; i < attrib_count; i++) + if(attributes!=NULL){ + for (i = 0; i < attrib_count; i++){ if (!strcmp(attributes[i].name, "XV_AUTOPAINT_COLORKEY")) { xv_atom = XInternAtom(mDisplay, "XV_AUTOPAINT_COLORKEY", False); @@ -220,7 +220,9 @@ } break; } + } XFree(attributes); + } } xv_atom = XInternAtom(mDisplay, "XV_COLORKEY",False);