diff options
author | Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br> | 2009-01-29 20:22:21 -0200 |
---|---|---|
committer | Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br> | 2009-01-29 20:22:21 -0200 |
commit | f16dd6af3eb17a25b8ee03d6617a7acc6e919fb0 (patch) | |
tree | e12f8e5f115785cc634fcf8a43b28d23dd920baa /modules | |
parent | cce75c5dce73fe1f8626ed9e6798138ada09a860 (diff) | |
download | xorg-lib-libX11-f16dd6af3eb17a25b8ee03d6617a7acc6e919fb0.tar.gz |
patches to avoid gcc warnings for libX11 (#3)
Author is Peter Breitenlohner <peb@mppmu.mpg.de>
Bug #17946, attachment #19441
This patch avoids the two gcc warnings
../../../../libX11-1.1.5/modules/im/ximcp/imRm.c:413: warning: assignment discards qualifiers from pointer target type
../../../../libX11-1.1.5/modules/im/ximcp/imRm.c:450: warning: assignment discards qualifiers from pointer target type
Note, that this as a rather crude fix of the problem (and it is really a
shame to cast name_table to non-const).
The right solution would be to declare XIMValuesList.supported_values
(in include/X11/Xlib.h) as 'const char **' (or '_Xconst char **').
This will, however, require extensive modifications in various places.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/im/ximcp/imRm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/im/ximcp/imRm.c b/modules/im/ximcp/imRm.c index 73f60206..9cdda3f7 100644 --- a/modules/im/ximcp/imRm.c +++ b/modules/im/ximcp/imRm.c @@ -410,7 +410,7 @@ _XimDefaultIMValues( = (char **)((char *)tmp + sizeof(XIMValuesList)); for(i = 0; i < n; i++) { values_list->supported_values[i] = - name_table + supported_local_im_values_list[i]; + (char *)name_table + supported_local_im_values_list[i]; } } @@ -447,7 +447,7 @@ _XimDefaultICValues( = (char **)((char *)tmp + sizeof(XIMValuesList)); for(i = 0; i < n; i++) { values_list->supported_values[i] = - name_table + supported_local_ic_values_list[i]; + (char *)name_table + supported_local_ic_values_list[i]; } } |