If we don't have pthreads, don't call thread pool functions
authoraland <aland>
Mon, 5 Jul 2004 15:16:48 +0000 (15:16 +0000)
committeraland <aland>
Mon, 5 Jul 2004 15:16:48 +0000 (15:16 +0000)
src/main/radiusd.c

index ca6192a..a45769b 100644 (file)
@@ -1301,6 +1301,7 @@ int main(int argc, char *argv[])
                         *      and let the thread pool take care of
                         *      doing something with it.
                         */
+#ifdef HAVE_PTHREAD_H
                        if (spawn_flag) {
                                if (!thread_pool_addrequest(request, fun)) {
                                        /*
@@ -1310,9 +1311,9 @@ int main(int argc, char *argv[])
                                        request_reject(request);
                                        request->finished = TRUE;
                                }
-                       } else {
+                       } else
+#endif
                                rad_respond(request, fun);
-                       }
                } /* loop over listening sockets*/
 
 #ifdef WITH_SNMP