diff options
author | Jeremy Huddleston <jeremyhu@freedesktop.org> | 2008-11-22 15:47:14 -0800 |
---|---|---|
committer | Jeremy Huddleston <jeremyhu@freedesktop.org> | 2008-11-25 00:54:17 -0800 |
commit | ab12c7516207908f3e063a78904d68e2db14208e (patch) | |
tree | 15d12c8d0db6fcae26c4e21049a17845e5820b52 | |
parent | 208f091bfc657e9ee57b988f035d3aac7e9e173a (diff) |
XQuartz: More Tiger cleanup: bootstrap_strerror
(cherry picked from commit 37f535aff3e9a7a02711daa98152cdff97745622)
-rw-r--r-- | hw/xquartz/mach-startup/bundle-main.c | 5 | ||||
-rw-r--r-- | hw/xquartz/mach-startup/stub.c | 6 |
2 files changed, 10 insertions, 1 deletions
diff --git a/hw/xquartz/mach-startup/bundle-main.c b/hw/xquartz/mach-startup/bundle-main.c index a49013e0d..d9c895ec3 100644 --- a/hw/xquartz/mach-startup/bundle-main.c +++ b/hw/xquartz/mach-startup/bundle-main.c @@ -29,6 +29,7 @@ prior written authorization. */ #include <CoreFoundation/CoreFoundation.h> +#include <AvailabilityMacros.h> #include <X11/Xlib.h> #include <unistd.h> @@ -374,7 +375,11 @@ int startup_trigger(int argc, char **argv, char **envp) { kr = bootstrap_look_up(bootstrap_port, SERVER_BOOTSTRAP_NAME, &mp); if (kr != KERN_SUCCESS) { +#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1050 fprintf(stderr, "bootstrap_look_up(): %s\n", bootstrap_strerror(kr)); +#else + fprintf(stderr, "bootstrap_look_up(): %ul\n", (unsigned long)kr); +#endif exit(EXIT_FAILURE); } diff --git a/hw/xquartz/mach-startup/stub.c b/hw/xquartz/mach-startup/stub.c index bc4f7eca0..aa0505a32 100644 --- a/hw/xquartz/mach-startup/stub.c +++ b/hw/xquartz/mach-startup/stub.c @@ -267,7 +267,11 @@ int main(int argc, char **argv, char **envp) { } if(kr != KERN_SUCCESS) { - fprintf(stderr, "Xquartz: bootstrap_look_up(): Timed out: %s\n", bootstrap_strerror(kr)); +#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1050 + fprintf(stderr, "Xquartz: bootstrap_look_up(): %s\n", bootstrap_strerror(kr)); +#else + fprintf(stderr, "Xquartz: bootstrap_look_up(): %ul\n", (unsigned long)kr); +#endif return EXIT_FAILURE; } } |