Back to index

php5  5.3.10
php_win32_globals.h
Go to the documentation of this file.
00001 /*
00002    +----------------------------------------------------------------------+
00003    | PHP Version 5                                                        |
00004    +----------------------------------------------------------------------+
00005    | Copyright (c) 1997-2012 The PHP Group                                |
00006    +----------------------------------------------------------------------+
00007    | This source file is subject to version 3.01 of the PHP license,      |
00008    | that is bundled with this package in the file LICENSE, and is        |
00009    | available through the world-wide-web at the following url:           |
00010    | http://www.php.net/license/3_01.txt                                  |
00011    | If you did not receive a copy of the PHP license and are unable to   |
00012    | obtain it through the world-wide-web, please send a note to          |
00013    | license@php.net so we can mail you a copy immediately.               |
00014    +----------------------------------------------------------------------+
00015    | Author: Wez Furlong <wez@php.net>                                    |
00016    +----------------------------------------------------------------------+
00017 */
00018 
00019 /* $Id: php_win32_globals.h 321634 2012-01-01 13:15:04Z felipe $ */
00020 
00021 #ifndef PHP_WIN32_GLOBALS_H
00022 #define PHP_WIN32_GLOBALS_H
00023 
00024 /* misc globals for thread-safety under win32 */
00025 
00026 typedef struct _php_win32_core_globals php_win32_core_globals;
00027 
00028 #ifdef ZTS
00029 # define PW32G(v)           TSRMG(php_win32_core_globals_id, php_win32_core_globals*, v)
00030 extern PHPAPI int php_win32_core_globals_id;
00031 #else
00032 # define PW32G(v)           (the_php_win32_core_globals.v)
00033 extern PHPAPI struct _php_win32_core_globals the_php_win32_core_globals;
00034 #endif
00035 
00036 struct _php_win32_core_globals {
00037        /* syslog */
00038        char *log_header;
00039        HANDLE log_source;
00040 
00041        /* time */
00042        struct timeval starttime;
00043        __int64                     lasttime, freq;
00044 
00045        HKEY       registry_key;
00046        HANDLE     registry_event;
00047        HashTable *registry_directories;
00048 };
00049 
00050 void php_win32_core_globals_ctor(void *vg TSRMLS_DC);
00051 void php_win32_core_globals_dtor(void *vg TSRMLS_DC);
00052 PHP_RSHUTDOWN_FUNCTION(win32_core_globals);
00053 
00054 #endif
00055