Commit 3c74d954 authored by Jeff Trawick's avatar Jeff Trawick
Browse files

fix the bindprocessor() code selection; we need to test for the

presence of the bindprocessor() function, not for sys/processor.h,
which exists on some systems that don't have bindprocessor()


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89352 13f79535-47bb-0310-9956-ffa450edef68
parent aca97e08
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -103,6 +103,9 @@
#include <sys/stat.h>
#include <sys/un.h>
#include <setjmp.h>
#ifdef HAVE_SYS_PROCESSOR_H
#include <sys/processor.h> /* for bindprocessor() */
#endif

/*
 * Actual definitions of config globals
@@ -967,11 +970,10 @@ static int make_child(server_rec *s, int slot)
    }

    if (!pid) {
#ifdef HAVE_SYS_PROCESSOR_H
#ifdef HAVE_BINDPROCESSOR
        /* By default, AIX binds to a single processor.  This bit unbinds
	 children which will then bind to another CPU.
         * children which will then bind to another CPU.
         */
#include <sys/processor.h>
        int status = bindprocessor(BINDPROCESS, (int)getpid(),
			       PROCESSOR_CLASS_ANY);
	if (status != OK)
+7 −5
Original line number Diff line number Diff line
@@ -103,6 +103,9 @@
#include <sys/stat.h>
#include <sys/un.h>
#include <setjmp.h>
#ifdef HAVE_SYS_PROCESSOR_H
#include <sys/processor.h> /* for bindprocessor() */
#endif

/*
 * Actual definitions of config globals
@@ -967,11 +970,10 @@ static int make_child(server_rec *s, int slot)
    }

    if (!pid) {
#ifdef HAVE_SYS_PROCESSOR_H
#ifdef HAVE_BINDPROCESSOR
        /* By default, AIX binds to a single processor.  This bit unbinds
	 children which will then bind to another CPU.
         * children which will then bind to another CPU.
         */
#include <sys/processor.h>
        int status = bindprocessor(BINDPROCESS, (int)getpid(),
			       PROCESSOR_CLASS_ANY);
	if (status != OK)
+7 −5
Original line number Diff line number Diff line
@@ -124,6 +124,9 @@
#ifdef HAVE_TIME_H
#include <time.h>
#endif
#ifdef HAVE_SYS_PROCESSOR_H
#include <sys/processor.h> /* for bindprocessor() */
#endif

#include <signal.h>
#include <sys/times.h>
@@ -868,11 +871,10 @@ static int make_child(server_rec *s, int slot)
    }

    if (!pid) {
#ifdef HAVE_SYS_PROCESSOR_H
#ifdef HAVE_BINDPROCESSOR
        /* by default AIX binds to a single processor
         * this bit unbinds children which will then bind to another cpu
         */
#include <sys/processor.h>
	int status = bindprocessor(BINDPROCESS, (int)getpid(), 
				   PROCESSOR_CLASS_ANY);
	if (status != OK) {