/usr/src/redhat/BUILD/httpd-2.2.3/os/win32/os.h

説明を見る。
00001 /* Licensed to the Apache Software Foundation (ASF) under one or more
00002  * contributor license agreements.  See the NOTICE file distributed with
00003  * this work for additional information regarding copyright ownership.
00004  * The ASF licenses this file to You under the Apache License, Version 2.0
00005  * (the "License"); you may not use this file except in compliance with
00006  * the License.  You may obtain a copy of the License at
00007  *
00008  *     http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  */
00016 
00028 #ifdef WIN32
00029 
00030 #ifndef AP_OS_H
00031 #define AP_OS_H
00032 /* Delegate windows include to the apr.h header, if USER or GDI declarations
00033  * are required (for a window rather than console application), include
00034  * windows.h prior to any other Apache header files.
00035  */
00036 #include "apr_pools.h"
00037 
00038 #include <io.h>
00039 #include <fcntl.h>
00040 
00041 #define PLATFORM "Win32"
00042 
00043 /* going away shortly... */
00044 #define HAVE_DRIVE_LETTERS
00045 #define HAVE_UNC_PATHS
00046 #define CASE_BLIND_FILESYSTEM
00047 
00048 #define APACHE_MPM_DIR  "server/mpm/winnt" /* generated on unix */
00049 
00050 #include <stddef.h>
00051 
00052 #ifdef __cplusplus
00053 extern "C" {
00054 #endif
00055 
00056 /* BIG RED WARNING: exit() is mapped to allow us to capture the exit
00057  * status.  This header must only be included from modules linked into
00058  * the ApacheCore.dll - since it's a horrible behavior to exit() from
00059  * any module outside the main() block, and we -will- assume it's a
00060  * fatal error.
00061  */
00062 
00063 AP_DECLARE_DATA extern int ap_real_exit_code;
00064 
00065 #define exit(status) ((exit)((ap_real_exit_code==2) \
00066                                 ? (ap_real_exit_code = (status)) \
00067                                 : ((ap_real_exit_code = 0), (status))))
00068 
00069 #ifdef AP_DECLARE_EXPORT
00070 
00071 /* Defined in util_win32.c and available only to the core module for
00072  * win32 MPM design.
00073  */
00074 
00075 AP_DECLARE(apr_status_t) ap_os_proc_filepath(char **binpath, apr_pool_t *p);
00076 
00077 typedef enum {
00078     AP_DLL_WINBASEAPI = 0,    // kernel32 From WinBase.h
00079     AP_DLL_WINADVAPI = 1,     // advapi32 From WinBase.h
00080     AP_DLL_WINSOCKAPI = 2,    // mswsock  From WinSock.h
00081     AP_DLL_WINSOCK2API = 3,   // ws2_32   From WinSock2.h
00082     AP_DLL_defined = 4        // must define as last idx_ + 1
00083 } ap_dlltoken_e;
00084 
00085 FARPROC ap_load_dll_func(ap_dlltoken_e fnLib, char* fnName, int ordinal);
00086 
00087 PSECURITY_ATTRIBUTES GetNullACL();
00088 void CleanNullACL(void *sa);
00089 
00090 DWORD wait_for_many_objects(DWORD nCount, CONST HANDLE *lpHandles, 
00091                             DWORD dwSeconds);
00092 
00093 int set_listeners_noninheritable(apr_pool_t *p);
00094 
00095 
00096 #define AP_DECLARE_LATE_DLL_FUNC(lib, rettype, calltype, fn, ord, args, names) \
00097     typedef rettype (calltype *ap_winapi_fpt_##fn) args; \
00098     static ap_winapi_fpt_##fn ap_winapi_pfn_##fn = NULL; \
00099     __inline rettype ap_winapi_##fn args \
00100     {   if (!ap_winapi_pfn_##fn) \
00101             ap_winapi_pfn_##fn = (ap_winapi_fpt_##fn) ap_load_dll_func(lib, #fn, ord); \
00102         return (*(ap_winapi_pfn_##fn)) names; }; \
00103 
00104 /* Win2K kernel only */
00105 AP_DECLARE_LATE_DLL_FUNC(AP_DLL_WINADVAPI, BOOL, WINAPI, ChangeServiceConfig2A, 0, (
00106     SC_HANDLE hService, 
00107     DWORD dwInfoLevel, 
00108     LPVOID lpInfo),
00109     (hService, dwInfoLevel, lpInfo));
00110 #undef ChangeServiceConfig2
00111 #define ChangeServiceConfig2 ap_winapi_ChangeServiceConfig2A
00112 
00113 /* WinNT kernel only */
00114 AP_DECLARE_LATE_DLL_FUNC(AP_DLL_WINBASEAPI, BOOL, WINAPI, CancelIo, 0, (
00115     IN HANDLE hFile),
00116     (hFile));
00117 #undef CancelIo
00118 #define CancelIo ap_winapi_CancelIo
00119 
00120 /* Win9x kernel only */
00121 AP_DECLARE_LATE_DLL_FUNC(AP_DLL_WINBASEAPI, DWORD, WINAPI, RegisterServiceProcess, 0, (
00122     DWORD dwProcessId,
00123     DWORD dwType),
00124     (dwProcessId, dwType));
00125 #define RegisterServiceProcess ap_winapi_RegisterServiceProcess
00126 
00127 #endif /* def AP_DECLARE_EXPORT */
00128 
00129 #ifdef __cplusplus
00130 }
00131 #endif
00132 
00133 #endif  /* ndef AP_OS_H */
00134 #endif  /* def WIN32 */
00135 

Apacheに対してSun Jul 19 22:05:23 2009に生成されました。  doxygen 1.4.7