version 1.1.1.1, 2012/02/21 23:48:06
|
version 1.1.1.4, 2014/06/15 20:04:03
|
Line 2
|
Line 2
|
+----------------------------------------------------------------------+ |
+----------------------------------------------------------------------+ |
| PHP Version 5 | |
| PHP Version 5 | |
+----------------------------------------------------------------------+ |
+----------------------------------------------------------------------+ |
| Copyright (c) 1997-2012 The PHP Group | | | Copyright (c) 1997-2014 The PHP Group | |
+----------------------------------------------------------------------+ |
+----------------------------------------------------------------------+ |
| This source file is subject to version 3.01 of the PHP license, | |
| This source file is subject to version 3.01 of the PHP license, | |
| that is bundled with this package in the file LICENSE, and is | |
| that is bundled with this package in the file LICENSE, and is | |
Line 22
|
Line 22
|
#include "php.h" |
#include "php.h" |
#include <wincrypt.h> |
#include <wincrypt.h> |
|
|
PHPAPI char *php_win_err(int error) | PHPAPI char *php_win32_error_to_msg(int error) |
{ |
{ |
char *buf = NULL; |
char *buf = NULL; |
|
|
Line 62 void php_win32_init_rng_lock()
|
Line 62 void php_win32_init_rng_lock()
|
void php_win32_free_rng_lock() |
void php_win32_free_rng_lock() |
{ |
{ |
tsrm_mutex_lock(php_lock_win32_cryptoctx); |
tsrm_mutex_lock(php_lock_win32_cryptoctx); |
CryptReleaseContext(hCryptProv, 0); | if (has_crypto_ctx == 1) { |
has_crypto_ctx = 0; | CryptReleaseContext(hCryptProv, 0); |
| has_crypto_ctx = 0; |
| } |
tsrm_mutex_unlock(php_lock_win32_cryptoctx); |
tsrm_mutex_unlock(php_lock_win32_cryptoctx); |
tsrm_mutex_free(php_lock_win32_cryptoctx); |
tsrm_mutex_free(php_lock_win32_cryptoctx); |
|
|