Skip to content

Instantly share code, notes, and snippets.

Avatar
🐟
Something fishy?

Kalle Sommer Nielsen KalleZ

🐟
Something fishy?
View GitHub Profile
View gist:cf310657f13f8370a581ff7522d13da6
$ php bug77390.php
Warning: openssl_x509_export_to_file(): Cannot get cert from parameter 1 in C:\php-sdk\master\vc15\x64\php-src\ext\openssl\tests\CertificateGenerator.inc on line 83
Warning: openssl_csr_sign(): Cannot get CSR from parameter 1 in C:\php-sdk\master\vc15\x64\php-src\ext\openssl\tests\CertificateGenerator.inc on line 115
Warning: openssl_x509_export(): Cannot get cert from parameter 1 in C:\php-sdk\master\vc15\x64\php-src\ext\openssl\tests\CertificateGenerator.inc on line 119
Warning: openssl_pkey_export(): Cannot get key from parameter 1 in C:\php-sdk\master\vc15\x64\php-src\ext\openssl\tests\CertificateGenerator.inc on line 122
View T_DOUBLE_COLON.diff
Zend/zend_language_parser.y | 20 ++++++++++----------
Zend/zend_language_scanner.l | 2 +-
ext/tokenizer/tests/001.phpt | 2 +-
ext/tokenizer/tokenizer_data.c | 6 +++---
ext/tokenizer/tokenizer_data_gen.sh | 6 +++---
5 files changed, 18 insertions(+), 18 deletions(-)
diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y
index c1ced9a35a..5b1a355b62 100644
--- a/Zend/zend_language_parser.y
View gist:12796fdd476adae31790284a28a52a55
c:\php-sdk\master\vc15\x64\php-src\ext\gd\gd_ctx.c(35): warning C4267: 'return': conversion from 'size_t' to 'int', possible loss of data
c:\php-sdk\master\vc15\x64\php-src\ext\gd\gd_ctx.c(54): warning C4244: 'return': conversion from 'SSIZE_T' to 'int', possible loss of data
c:\php-sdk\master\vc15\x64\php-src\ext\gd\gd_ctx.c(127): warning C4244: '=': conversion from 'zend_long' to 'int', possible loss of data
c:\php-sdk\master\vc15\x64\php-src\ext\gd\gd_ctx.c(129): warning C4244: '=': conversion from 'zend_long' to 'int', possible loss of data
ext\gd\gd.c(711): warning C4244: '=': conversion from 'SSIZE_T' to 'int', possible loss of data
ext\gd\gd.c(725): warning C4244: '=': conversion from 'zend_off_t' to 'int', possible loss of data
ext\gd\gd.c(727): warning C4244: '=': conversion from 'zend_off_t' to 'int', possible loss of data
ext\gd\gd.c(754): warning C4244: '=': conversion from 'SSIZE_T' to 'int', possible loss of data
ext\gd\gd.c(809): warning C4244: '=': conversion from 'zend_long' to 'int', possibl
View ezmlm-sub-master.diff
entry/subscribe.php | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/entry/subscribe.php b/entry/subscribe.php
index e25f382..4fab412 100644
--- a/entry/subscribe.php
+++ b/entry/subscribe.php
@@ -31,17 +31,15 @@ if (!preg_match("!^[a-z0-9-]+$!", $_POST['maillist'])) {
die("Invalid mailing list name");
}
View virtualprotect.diff
ext/opcache/ZendAccelerator.c | 10 ++++++++--
ext/opcache/zend_shared_alloc.c | 18 ++++++++++++++++++
2 files changed, 26 insertions(+), 2 deletions(-)
diff --git a/ext/opcache/ZendAccelerator.c b/ext/opcache/ZendAccelerator.c
index 7879de866f..802e7ed23b 100644
--- a/ext/opcache/ZendAccelerator.c
+++ b/ext/opcache/ZendAccelerator.c
@@ -133,8 +133,14 @@ static void preload_activate(void);
static void preload_restart(void);
View gist:d3c48f6b2143ce37ba1c2eb8f243f0aa
Recreating build dirs
ZendAccelerator.c
shared_alloc_win32.c
zend_accelerator_blacklist.c
zend_accelerator_debug.c
c:\php-sdk\master\vc15\x64\php-src\ext\opcache\ZendAccelerator.h(265): warning C4146: unary minus operator applied to unsigned type, result still unsigned (compiling source file ext\opcache\shared_alloc_win32.c)
ext\opcache\shared_alloc_win32.c(94): warning C4267: '=': conversion from 'size_t' to 'int', possible loss of data
c:\php-sdk\master\vc15\x64\php-src\ext\opcache\ZendAccelerator.h(265): warning C4146: unary minus operator applied to unsigned type, result still unsigned (compiling source file ext\opcache\zend_accelerator_debug.c)
c:\php-sdk\master\vc15\x64\php-src\ext\opcache\ZendAccelerator.h(265): warning C4146: unary minus operator applied to unsigned type, result still unsigned (compiling source file ext\opcache\ZendAccelerator.c)
c:\php-sdk\master\vc15\x64\php-src\ext\opcache\ZendAccelerator.h(265): warning C4146: unary minus operator applied to unsigned type, result still unsigned (c
View remove-pcre-defs.diff
diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c
index 52da36c2cf..0b42683e40 100644
--- a/ext/mbstring/mbstring.c
+++ b/ext/mbstring/mbstring.c
@@ -60,7 +60,7 @@
# include "php_onig_compat.h"
# include <oniguruma.h>
# undef UChar
-#elif HAVE_PCRE || HAVE_BUNDLED_PCRE
+#else
View gist:f41a7272c98a0ee2c8db74a4e81681bd
C:\dev>php -v
PHP 7.3.1 (cli) (built: Jan 9 2019 22:20:52) ( ZTS MSVC15 (Visual C++ 2017) x64 )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.1, Copyright (c) 1998-2018 Zend Technologies
C:\dev>php foo.php
6
123456
C:\dev>
View php-intrin.diff
diff --git a/.gitignore b/.gitignore
index c0e059714d..e0b5b7211e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -225,6 +225,8 @@ php
/main/config.w32.h
/win32/build/deplister.exe
/win32/build/deplister.obj
+/win32/build/cpuinfo.exe
+/win32/build/cpuinfo.obj
View hardcode-mysqli-no-change-user-on-pconnect.diff
ext/mysqli/config.w32 | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/ext/mysqli/config.w32 b/ext/mysqli/config.w32
index 4d8630c27d..aeb9a1512d 100644
--- a/ext/mysqli/config.w32
+++ b/ext/mysqli/config.w32
@@ -22,7 +22,7 @@ if (PHP_MYSQLI != "no") {
"mysqli_warning.c";