mirror of
https://gitlab.freedesktop.org/xorg/lib/libx11.git
synced 2026-05-07 06:18:04 +02:00
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.
This commit is contained in:
parent
cce75c5dce
commit
f16dd6af3e
1 changed files with 2 additions and 2 deletions
|
|
@ -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];
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue