X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=utils%2Fgrabclient.c;h=47d1c3bd5d5ebb3a1d3f95885ae2586c39130f3b;hb=8afc01a67be4fbf3f1cc0fce9adf01b5289a21c6;hp=082f1f167a7e5a62dafda935e156b4a9da99e510;hpb=4ade52359b6eba3621566dac79793a33aa4c915f;p=xscreensaver diff --git a/utils/grabclient.c b/utils/grabclient.c index 082f1f16..47d1c3bd 100644 --- a/utils/grabclient.c +++ b/utils/grabclient.c @@ -564,6 +564,7 @@ pipe_cb (XtPointer closure, int *source, XtInputId *id) char buf[10240]; const char *dir = clo2->directory; char *absfile = 0; + *buf = 0; fgets (buf, sizeof(buf)-1, clo2->pipe); pclose (clo2->pipe); clo2->pipe = 0; @@ -629,7 +630,7 @@ pipe_cb (XtPointer closure, int *source, XtInputId *id) /* Replace slashes with newlines */ /* while (dot = strchr(buf, '/')) *dot = '\n'; */ /* Replace slashes with spaces */ - while ((dot = strchr(buf, '/'))) *dot = ' '; + /* while ((dot = strchr(buf, '/'))) *dot = ' '; */ } if (absfile) free (absfile); @@ -861,7 +862,7 @@ print_loading_msg (Screen *screen, Window window) fn = 0; XGetWindowAttributes (dpy, window, &xgwa); - w = XTextWidth (f, text, strlen(text)); + w = XTextWidth (f, text, (int) strlen(text)); gcv.foreground = get_pixel_resource (dpy, xgwa.colormap, "foreground", "Foreground"); @@ -872,7 +873,7 @@ print_loading_msg (Screen *screen, Window window) XDrawImageString (dpy, window, gc, (xgwa.width - w) / 2, (xgwa.height - (f->ascent + f->descent)) / 2 + f->ascent, - text, strlen(text)); + text, (int) strlen(text)); XFreeFont (dpy, f); XFreeGC (dpy, gc); XSync (dpy, False);