[MPlayer-users] BUGREPORT: this commit broke metacity-fullscreen-switch

Dominik Mierzejewski dominik at rangers.eu.org
Wed Oct 16 15:03:09 CEST 2002


On Wednesday, 16 October 2002, gabor wrote:
> [Automatic answer: RTFM (read DOCS, FAQ), also read DOCS/bugreports.html]
> hi,
> 
> this commit:
> http://mplayerhq.hu/pipermail/mplayer-cvslog/2002-October/010930.html:
> 
> ---------------------------------
> Update of /cvsroot/mplayer/main/libvo
> In directory mail:/var/tmp.root/cvs-serv26705/libvo
> 
> Modified Files:
> 	x11_common.c 
> Log Message:
> compiler warning fixes
> patch by Dominik Mierzejewski <dominik at rangers.eu.org>
> 
> 
> Index: x11_common.c
> ===================================================================
> RCS file: /cvsroot/mplayer/main/libvo/x11_common.c,v
> retrieving revision 1.103
> retrieving revision 1.104
> diff -u -r1.103 -r1.104
> --- x11_common.c	6 Oct 2002 18:21:13 -0000	1.103
> +++ x11_common.c	13 Oct 2002 21:58:55 -0000	1.104
> @@ -635,7 +635,7 @@
>   Atom            type;
>   int             format;
>   unsigned long   nitems, bytesafter;
> - Atom          * args = NULL;
> + unsigned char   * args = NULL;
>  
>   if ( WinID >= 0 ) return;
>   
> 
> 
> -------------------------------------
> after this patch got applied, the old
> metacity-unable-to-switch-back-from-fullscreen appeared again.
> 
> if i replace unsigned_char with Atom, it works again.
> 
> gcc3.2

How strange.
$ less x11_common.c
[...]
 if ( Success == XGetWindowProperty(
 mDisplay,mRootWin,type,0,16384,False,AnyPropertyType,&type,&format,&nitems,&bytesafter,&args
                                                                                        ^^^^^
 ) && nitems > 0 )
[...]
$ man XGetWindowProperty
[...]
SYNTAX
       int XGetWindowProperty(display, w, property, long_offset, long_length, delete,
       req_type,
                               actual_type_return, actual_format_return, nitems_return,
       bytes_after_return,
                               prop_return)
                               ^^^^^^^^^^^
             Display *display;
             Window w;
             Atom property;
             long long_offset, long_length;
             Bool delete;
             Atom req_type;
             Atom *actual_type_return;
             int *actual_format_return;
             unsigned long *nitems_return;
             unsigned long *bytes_after_return;
             unsigned char **prop_return;
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[...]

So according to the manpage the last argument should be unsigned char **, not Atom **.

PS. This should go to mplayer-dev-eng (Cc'd).
 
-- 
MPlayer RPMs maintainer: http://www.piorunek.pl/~dominik/linux/pkgs/mplayer/
"The Universe doesn't give you any points for doing things that are easy."
        -- Sheridan to Garibaldi in Babylon 5:"The Geometry of Shadows"




More information about the MPlayer-users mailing list