Mercurial > emacs
changeset 109759:779e72b463fd
Shut up compiler warnings due to "char *" and "const char *".
w32menu.c (add_menu_item): Use explicit cast to "char *".
(name_is_separator): Make `name' and `start' be "const char *".
author | Eli Zaretskii <eliz@gnu.org> |
---|---|
date | Fri, 13 Aug 2010 11:10:05 +0300 |
parents | 6fb5db53272f |
children | 0217a9452703 410b495bd9be |
files | src/ChangeLog src/w32menu.c |
diffstat | 2 files changed, 8 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog Fri Aug 13 08:57:12 2010 +0200 +++ b/src/ChangeLog Fri Aug 13 11:10:05 2010 +0300 @@ -1,3 +1,8 @@ +2010-08-13 Eli Zaretskii <eliz@gnu.org> + + * w32menu.c (add_menu_item, name_is_separator): Shut up compiler + warnings due to mixing of "char *" and "const char *". + 2010-08-12 Stefan Monnier <monnier@iro.umontreal.ca> Introduce a new comment style "c" flag.
--- a/src/w32menu.c Fri Aug 13 08:57:12 2010 +0200 +++ b/src/w32menu.c Fri Aug 13 11:10:05 2010 +0300 @@ -1280,9 +1280,9 @@ /* Is this item a separator? */ static int -name_is_separator (char *name) +name_is_separator (const char *name) { - char *start = name; + const char *start = name; /* Check if name string consists of only dashes ('-'). */ while (*name == '-') name++; @@ -1360,7 +1360,7 @@ strcat (out_string, wv->key); } else - out_string = wv->name; + out_string = (char *)wv->name; /* Quote any special characters within the menu item's text and key binding. */