summaryrefslogtreecommitdiff
path: root/win32/param.h
diff options
context:
space:
mode:
authorChristoph M. Becker <cmbecker69@gmx.de>2020-08-05 08:59:41 +0200
committerChristoph M. Becker <cmbecker69@gmx.de>2020-09-21 16:25:31 +0200
commit3e33e1e86d15e262cd9e0224a9604e252f5d9284 (patch)
tree8cb9f1178c8d2d287144c7be3cf7c7037c7bd72a /win32/param.h
parent6fa2493789f8f05c7a53eca803227fcfb1bf2573 (diff)
downloadphp-git-3e33e1e86d15e262cd9e0224a9604e252f5d9284.tar.gz
Check linker compatibility directly from HMODULE
Checking the linker compatibility with extranous `ImageLoad()` calls is possible, but unnecessary, since the modules are either already loaded or loaded shortly afterwards, so that we can get the required information directly from the module handles. And actually, doing `ImageLoad()` as well as `LoadLibrary()` leaves a tiny room for a race condition, because both functions will lookup the module in the search path, so there is no *guarantee* that both are dealing with the same module. Dropping the `ImageLoad()` calls also has the advantage to no longer face the issue reported in bug #79557. A very minor additional advantage is that we no longer have to link against Imagehlp.dll. Furthermore, there is no need to check for CRT compatibility multiple times, so we can simplify the signature of `php_win32_crt_compatible`, and at the same time clean up main.c a bit. These changes require to change the signature of the exported `php_win32_image_compatible` and `php_win32_crt_compatible` functions, which now expect a `HMODULE` and nothing, respectively, instead of the module name.
Diffstat (limited to 'win32/param.h')
0 files changed, 0 insertions, 0 deletions