1
0
mirror of https://github.com/php/php-src.git synced 2026-04-09 17:13:31 +02:00
Files
archived-php-src/ext
Christoph M. Becker a385cfa7ad Fix #63208: BSTR to PHP string conversion not binary safe
A `BSTR` is similar to a `zend_string`; it stores the length of the
string just before the actual string, and thus the string may contain
NUL bytes.  However, `php_com_olestring_to_string()` is supposed to
deal with arbitrary `OLECHAR*`s which may not be `BSTR`s, so we
introduce `php_com_bstr_to_string()` and use it for the only case where
we actually have to deal with `BSTR`s which may contain NUL bytes.

Contrary to `php_com_olestring_to_string()` we return a `zend_string`,
so we can save the re-allocation when converting to a `zval`.

We also cater to `php_com_string_to_olestring()` not being binary safe,
with basically the same fix we did for `php_com_olestring_to_string()`.
2020-06-29 19:05:02 +02:00
..
2019-12-16 10:32:49 -08:00
2020-01-11 06:15:32 +14:00
2020-06-26 12:28:39 +02:00
2020-04-24 12:31:30 +01:00
2020-06-23 15:57:24 +02:00
2019-04-06 19:06:16 -07:00
2020-02-03 13:03:54 +01:00
2019-04-23 12:43:32 +02:00
2019-08-20 13:58:22 +02:00
2020-04-23 17:35:09 +02:00
2019-04-06 01:27:58 +02:00
2019-04-10 13:06:55 +02:00
2020-06-19 17:31:28 +02:00
2020-02-28 17:06:05 +01:00
2019-10-01 11:15:12 +02:00
2020-02-16 22:40:25 -08:00
2020-06-19 10:46:26 +02:00