com php-src: Revert "Fix VC compilation as variable size array is not supported": ext/mysqlnd/mysqlnd_wireprotocol.c
| From: | Joe Watkins | Date: | Wed, 20 Jun 2018 17:25:01 +0000 |
| Subject: | com php-src: Revert "Fix VC compilation as variable size array is not supported": ext/mysqlnd/mysqlnd_wireprotocol.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-102211@lists.php.net to get a copy of this message | ||
Commit: 73399c1bc15e679b763f11551141b3c5683ef83b
Author: Joe Watkins <krakjoe@php.net> Wed, 20 Jun 2018 19:25:01 +0200
Parents: e73cc6b2c25f2424d880483374876a6278775482
Branches: PHP-7.1.19
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=73399c1bc15e679b763f11551141b3c5683ef83b
Log:
Revert "Fix VC compilation as variable size array is not supported"
This reverts commit f96df64cb2219fda42ca875483f874cf3052647c.
Changed paths:
M ext/mysqlnd/mysqlnd_wireprotocol.c
Diff:
diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c
index c5039c3..e782d99 100644
--- a/ext/mysqlnd/mysqlnd_wireprotocol.c
+++ b/ext/mysqlnd/mysqlnd_wireprotocol.c
@@ -2277,12 +2277,7 @@ size_t php_mysqlnd_cached_sha2_result_write(void * _packet)
MYSQLND_PFC * pfc = packet->header.protocol_frame_codec;
MYSQLND_VIO * vio = packet->header.vio;
MYSQLND_STATS * stats = packet->header.stats;
-#ifndef _MSC_VER
zend_uchar buffer[MYSQLND_HEADER_SIZE + packet->password_len + 1];
-#else
- ALLOCA_FLAG(use_heap)
- zend_uchar *buffer = do_alloca(MYSQLND_HEADER_SIZE + packet->password_len + 1, use_heap);
-#endif
size_t sent;
DBG_ENTER("php_mysqlnd_cached_sha2_result_write");
@@ -2295,10 +2290,6 @@ size_t php_mysqlnd_cached_sha2_result_write(void * _packet)
sent = pfc->data->m.send(pfc, vio, buffer, packet->password_len, stats, error_info);
}
-#ifdef _MSC_VER
- free_alloca(buffer, use_heap);
-#endif
-
DBG_RETURN(sent);
}