XQuartz: More Tiger cleanup: bootstrap_strerror
(cherry picked from commit 37f535aff3e9a7a02711daa98152cdff97745622)
This commit is contained in:
parent
208f091bfc
commit
ab12c75162
|
@ -29,6 +29,7 @@
|
||||||
prior written authorization. */
|
prior written authorization. */
|
||||||
|
|
||||||
#include <CoreFoundation/CoreFoundation.h>
|
#include <CoreFoundation/CoreFoundation.h>
|
||||||
|
#include <AvailabilityMacros.h>
|
||||||
|
|
||||||
#include <X11/Xlib.h>
|
#include <X11/Xlib.h>
|
||||||
#include <unistd.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);
|
kr = bootstrap_look_up(bootstrap_port, SERVER_BOOTSTRAP_NAME, &mp);
|
||||||
if (kr != KERN_SUCCESS) {
|
if (kr != KERN_SUCCESS) {
|
||||||
|
#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1050
|
||||||
fprintf(stderr, "bootstrap_look_up(): %s\n", bootstrap_strerror(kr));
|
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);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -267,7 +267,11 @@ int main(int argc, char **argv, char **envp) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(kr != KERN_SUCCESS) {
|
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;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue