From 1cfa1c94b01303aa9f1c3327e3bbdb53834d0322 Mon Sep 17 00:00:00 2001 From: Roland Mainz Date: Sun, 17 Oct 2004 23:08:07 +0000 Subject: Fix for https://freedesktop.org/bugzilla/show_bug.cgi?id=1659 - Fix Imakefile bug which caused the Xprint support in "xset" not being build. --- xset.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/xset.c b/xset.c index c2c4ab3..6be4f4e 100644 --- a/xset.c +++ b/xset.c @@ -88,7 +88,7 @@ in this Software without prior written authorization from The Open Group. static Status set_font_cache(Display *, long, long, long); static void query_cache_status(Display *dpy); #endif -#ifdef INCLUDE_XPRINT_SUPPORT +#ifdef BUILD_PRINTSUPPORT #include #endif @@ -206,7 +206,7 @@ dpy = XOpenDisplay(disp); /* Open display and check for success */ if (dpy == NULL) { fprintf(stderr, "%s: unable to open display \"%s\"\n", argv[0], XDisplayName (disp)); - exit(1); + exit(EXIT_FAILURE); } XSetErrorHandler (local_xerror); for (i = 1; i < argc; ) { @@ -356,7 +356,7 @@ for (i = 1; i < argc; ) { } } #endif -#ifdef INCLUDE_XPRINT_SUPPORT +#ifdef BUILD_PRINTSUPPORT else if (strcmp(arg, "rehashprinterlist") == 0) { /* rehash list of printers */ short dummy; if (XpQueryVersion(dpy, &dummy, &dummy)) { @@ -517,20 +517,20 @@ for (i = 1; i < argc; ) { { fprintf(stderr, "illegal combination of values\n"); fprintf(stderr, " standby time of %d is greater than suspend time of %d\n", standby_timeout, suspend_timeout); - exit(0); + exit(EXIT_FAILURE); } if ((off_timeout != 0)&&(suspend_timeout > off_timeout)) { fprintf(stderr, "illegal combination of values\n"); fprintf(stderr, " suspend time of %d is greater than off time of %d\n", suspend_timeout, off_timeout); - exit(0); + exit(EXIT_FAILURE); } if ((suspend_timeout == 0)&&(off_timeout != 0)&& (standby_timeout > off_timeout)) { fprintf(stderr, "illegal combination of values\n"); fprintf(stderr, " standby time of %d is greater than off time of %d\n", standby_timeout, off_timeout); - exit(0); + exit(EXIT_FAILURE); } DPMSEnable(dpy); DPMSSetTimeouts(dpy, standby_timeout, suspend_timeout, off_timeout); @@ -948,7 +948,7 @@ set_font_path(Display *dpy, char *path, int special, int before, int after) fprintf (stderr, "%s: internal error, only parsed %d of %d directories.\n", progName, i, ndirs); - exit (1); + exit (EXIT_FAILURE); } } @@ -1513,7 +1513,7 @@ usage(char *fmt, ...) fprintf (stderr, " Show font cache statistics:\n"); fprintf (stderr, "\t fc s\n"); #endif -#ifdef INCLUDE_XPRINT_SUPPORT +#ifdef BUILD_PRINTSUPPORT fprintf (stderr, " To control Xprint features:\n"); fprintf (stderr, "\t rehashprinterlist Recomputes the list of available printers\n"); #endif @@ -1546,14 +1546,14 @@ usage(char *fmt, ...) fprintf (stderr, "\t s expose s noexpose\n"); fprintf (stderr, "\t s activate s reset\n"); fprintf (stderr, " For status information: q\n"); - exit(0); + exit(EXIT_SUCCESS); } static void error(char *message) { fprintf( stderr, "%s: %s\n", progName, message ); - exit( 1 ); + exit(EXIT_FAILURE); } -- cgit v1.2.3