Main Page | Modules | Data Structures | File List | Data Fields | Globals | Related Pages

apr_signal.h

Go to the documentation of this file.
00001 /* Copyright 2000-2004 The Apache Software Foundation 00002 * 00003 * Licensed under the Apache License, Version 2.0 (the "License"); 00004 * you may not use this file except in compliance with the License. 00005 * You may obtain a copy of the License at 00006 * 00007 * http://www.apache.org/licenses/LICENSE-2.0 00008 * 00009 * Unless required by applicable law or agreed to in writing, software 00010 * distributed under the License is distributed on an "AS IS" BASIS, 00011 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00012 * See the License for the specific language governing permissions and 00013 * limitations under the License. 00014 */ 00015 00016 #ifndef APR_SIGNAL_H 00017 #define APR_SIGNAL_H 00018 00024 #include "apr.h" 00025 #include "apr_pools.h" 00026 00027 #if APR_HAVE_SIGNAL_H 00028 #include <signal.h> 00029 #endif 00030 00031 #ifdef __cplusplus 00032 extern "C" { 00033 #endif /* __cplusplus */ 00034 00041 #if APR_HAVE_SIGACTION || defined(DOXYGEN) 00042 00043 #if defined(DARWIN) && !defined(__cplusplus) && !defined(_ANSI_SOURCE) 00044 /* work around Darwin header file bugs 00045 * http://www.opensource.apple.com/bugs/X/BSD%20Kernel/2657228.html 00046 */ 00047 #undef SIG_DFL 00048 #undef SIG_IGN 00049 #undef SIG_ERR 00050 #define SIG_DFL (void (*)(int))0 00051 #define SIG_IGN (void (*)(int))1 00052 #define SIG_ERR (void (*)(int))-1 00053 #endif 00054 00056 typedef void apr_sigfunc_t(int); 00057 00063 APR_DECLARE(apr_sigfunc_t *) apr_signal(int signo, apr_sigfunc_t * func); 00064 00065 #if defined(SIG_IGN) && !defined(SIG_ERR) 00066 #define SIG_ERR ((apr_sigfunc_t *) -1) 00067 #endif 00068 00069 #else /* !APR_HAVE_SIGACTION */ 00070 #define apr_signal(a, b) signal(a, b) 00071 #endif 00072 00073 00079 APR_DECLARE(const char *) apr_signal_description_get(int signum); 00080 00082 APR_DECLARE(const char *) apr_signal_get_description(int signum); 00083 00089 void apr_signal_init(apr_pool_t *pglobal); 00090 00093 #ifdef __cplusplus 00094 } 00095 #endif /* __cplusplus */ 00096 00097 #endif /* APR_SIGNAL_H */

Generated on Tue Aug 10 17:42:34 2004 for Apache Portable Runtime by doxygen 1.3.7