File xvkbd-3.0-compilerwarnings.diff of Package xvkbd
Index: xvkbd-3.8/xvkbd.c
===================================================================
--- xvkbd-3.8.orig/xvkbd.c
+++ xvkbd-3.8/xvkbd.c
@@ -482,7 +482,7 @@ static Window focused_subwindow = None;
static Pixmap xvkbd_pixmap = None;
static int AddKeysym(KeySym keysym, Boolean top); /* forward */
-static void SendString(const unsigned char *str);
+static void SendString(const char *str);
static void MakeKeyboard(Boolean remake);
static void MakeKeypad(Widget form, Widget from_vert, Widget from_horiz);
static void MakeSunFunctionKey(Widget form, Widget from_vert, Widget from_horiz);
@@ -1502,9 +1502,9 @@ static void PopupCompletionPanel(void)
*/
static void KeyPressed(Widget w, char *key, char *data);
-static void SendString(const unsigned char *str)
+static void SendString(const char *str)
{
- const unsigned char *cp, *cp2; /* I remember "unsigned" might be required for some systems */
+ const char *cp, *cp2; /* I remember "unsigned" might be required for some systems */
char key[50];
int len;
int val;
@@ -2333,7 +2333,9 @@ static void MenuSelected(Widget w, char
Widget form;
if (strcmp(key, "man") == 0) {
- if (!appres.secure) system(appres.show_manual_command);
+ if (!appres.secure) {
+ if (system(appres.show_manual_command) == -1) fprintf(stderr, "Error call: %s\n", appres.show_manual_command);
+ }
} else if (strcmp(key, "about") == 0) {
if (about_panel == None) {
about_panel = XtVaCreatePopupShell("about_panel", transientShellWidgetClass,
@@ -2526,7 +2528,9 @@ static void KeyPressed(Widget w, char *k
if (appres.debug) fprintf(stderr, "Assigned string: %s\n", value);
if (value[0] == '!') {
if (appres.debug) fprintf(stderr, "Launching: %s\n", value + 1);
- if (!appres.secure) system(value + 1);
+ if (!appres.secure) {
+ if (system(value + 1) == -1) fprintf(stderr, "Could not Launch: %s\n", value + 1);
+ }
} else {
if (value[0] == '\\') value = value + 1;
if (appres.debug) fprintf(stderr, "Sending: %s\n", value);
@@ -2696,9 +2700,13 @@ static void KeyPressed(Widget w, char *k
if ((cur_shift & ControlMask) && (cur_shift & alt_mask)) {
if (strstr(XServerVendor(dpy), "XFree86") != NULL) {
if (strcmp(key1, "KP_Add") == 0) {
- if (!appres.secure) system("xvidtune -next");
+ if (!appres.secure) {
+ if (system("xvidtune -next") == -1) fprintf(stderr, "Error call system(xvidtune -next)\n");
+ }
} else if (strcmp(key1, "KP_Subtract") == 0) {
- if (!appres.secure) system("xvidtune -prev");
+ if (!appres.secure) {
+ if (system("xvidtune -prev") == -1) fprintf(stderr, "Error call system(xvidtune -prev)\n");
+ }
}
}
}