diff options
Diffstat (limited to 'zstd-pr57.patch')
-rw-r--r-- | zstd-pr57.patch | 90 |
1 files changed, 90 insertions, 0 deletions
diff --git a/zstd-pr57.patch b/zstd-pr57.patch new file mode 100644 index 0000000..92ed1ef --- /dev/null +++ b/zstd-pr57.patch @@ -0,0 +1,90 @@ +From 206c1042ed7f813a717d81217fd325c1d15e91f2 Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Fri, 28 Apr 2023 08:01:46 +0200 +Subject: [PATCH 1/3] fix [-Wunused-variable] + +--- + zstd.c | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/zstd.c b/zstd.c +index 06e0549..81694a0 100644 +--- a/zstd.c ++++ b/zstd.c +@@ -592,7 +592,6 @@ static size_t php_zstd_comp_write(php_stream *stream, const char *buf, size_t co + #else + static ssize_t php_zstd_comp_write(php_stream *stream, const char *buf, size_t count) + { +- ssize_t ret = 0; + #endif + + STREAM_DATA_FROM_STREAM(); + +From 3a37d5417c08e640629b2558da5829bf3609e960 Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Fri, 28 Apr 2023 08:02:26 +0200 +Subject: [PATCH 2/3] fix [-Wpointer-sign] + +--- + zstd.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/zstd.c b/zstd.c +index 81694a0..6c1310a 100644 +--- a/zstd.c ++++ b/zstd.c +@@ -855,7 +855,7 @@ static int APC_SERIALIZER_NAME(zstd)(APC_SERIALIZER_ARGS) + } + + size = ZSTD_compressBound(ZSTR_LEN(var.s)); +- *buf = (char*) emalloc(size + 1); ++ *buf = emalloc(size + 1); + + *buf_len = ZSTD_compress(*buf, size, ZSTR_VAL(var.s), ZSTR_LEN(var.s), + DEFAULT_COMPRESS_LEVEL); + +From ee6c47a34616c69af7bc0c27a7f4a3b948c461df Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Fri, 28 Apr 2023 08:05:21 +0200 +Subject: [PATCH 3/3] use normalized macro name + +--- + php_zstd.h | 2 +- + zstd.c | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/php_zstd.h b/php_zstd.h +index 731ae23..8aca8f8 100644 +--- a/php_zstd.h ++++ b/php_zstd.h +@@ -24,7 +24,7 @@ + #ifndef PHP_ZSTD_H + #define PHP_ZSTD_H + +-#define PHP_ZSTD_EXT_VERSION "0.12.1" ++#define PHP_ZSTD_VERSION "0.12.2" + #define PHP_ZSTD_NS "Zstd" + + extern zend_module_entry zstd_module_entry; +diff --git a/zstd.c b/zstd.c +index 6c1310a..924df38 100644 +--- a/zstd.c ++++ b/zstd.c +@@ -955,7 +955,7 @@ ZEND_MINFO_FUNCTION(zstd) + { + php_info_print_table_start(); + php_info_print_table_row(2, "Zstd support", "enabled"); +- php_info_print_table_row(2, "Extension Version", PHP_ZSTD_EXT_VERSION); ++ php_info_print_table_row(2, "Extension Version", PHP_ZSTD_VERSION); + php_info_print_table_row(2, "Interface Version", ZSTD_VERSION_STRING); + #if defined(HAVE_APCU_SUPPORT) + php_info_print_table_row(2, "APCu serializer ABI", APC_SERIALIZER_ABI); +@@ -1023,7 +1023,7 @@ zend_module_entry zstd_module_entry = { + NULL, + NULL, + ZEND_MINFO(zstd), +- PHP_ZSTD_EXT_VERSION, ++ PHP_ZSTD_VERSION, + STANDARD_MODULE_PROPERTIES + }; + |