Fixup fromcvs/togit conversion
[minix-pkgsrc.git] / editors / nedit / patches / patch-source_userCmds.c
blob0594b4b2e006fdff987764cf7d5109f4f00706cf
1 $NetBSD$
3 Silence gcc warnings about unsafe pointer casts.
4 Call <ctype.h> functions correctly.
6 --- source/userCmds.c~ 2004-09-02 08:50:38.000000000 +0000
7 +++ source/userCmds.c
8 @@ -1116,7 +1116,7 @@ static void dimSelDepItemsInMenu(Widget
9 XtVaGetValues(items[n], XmNsubMenuId, &subMenu, NULL);
10 dimSelDepItemsInMenu(subMenu, menuList, nMenuItems, sensitive);
11 } else {
12 - index = (int)userData - 10;
13 + index = (intptr_t)userData - 10;
14 if (index <0 || index >= nMenuItems)
15 return;
16 if (menuList[index]->input == FROM_SELECTION)
17 @@ -2864,7 +2864,7 @@ static void generateAcceleratorString(ch
18 /* for a consistent look to the accelerator names in the menus,
19 capitalize the first letter of the keysym */
20 strcpy(keyName, XKeysymToString(keysym));
21 - *keyName = toupper(*keyName);
22 + *keyName = toupper((unsigned char)*keyName);
24 /* concatenate the strings together */
25 sprintf(text, "%s%s%s%s%s%s%s%s", shiftStr, ctrlStr, altStr,
26 @@ -2946,7 +2946,7 @@ static int parseAcceleratorString(const
27 of the keysyms are "prettied up" by generateAcceleratorString */
28 *keysym = XStringToKeysym(fields[nFields-1]);
29 if (*keysym == NoSymbol) {
30 - *fields[nFields-1] = tolower(*fields[nFields-1]);
31 + *fields[nFields-1] = tolower((unsigned char)*fields[nFields-1]);
32 *keysym = XStringToKeysym(fields[nFields-1]);
33 if (*keysym == NoSymbol)
34 return False;