Skip to content

Commit

Permalink
Fix GH-2209: update return value and changelog of stream_set_chunk_si…
Browse files Browse the repository at this point in the history
…ze()
  • Loading branch information
alexandre-daubois committed Aug 8, 2023
1 parent 660cdbf commit 0768cd9
Showing 1 changed file with 35 additions and 3 deletions.
38 changes: 35 additions & 3 deletions reference/stream/functions/stream-set-chunk-size.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,19 +46,51 @@
Returns the previous chunk size on success.
</para>
<para>
Will return &false; if <parameter>size</parameter> is less than 1 or
greater than <constant>PHP_INT_MAX</constant>.
Prior to PHP 8.0.0, the function returned &false; if
<parameter>size</parameter> is less than 1 or greater than
<constant>PHP_INT_MAX</constant>.
</para>
</refsect1>

<refsect1 role="errors">
&reftitle.errors;
<para>
Will emit an <constant>E_WARNING</constant> level error if <parameter>size</parameter>
A <classname>ValueError</classname> is thrown if <parameter>size</parameter>
is less than 1 or greater than <constant>PHP_INT_MAX</constant>.
</para>
<para>
Prior to PHP 8.0.0, the function emitted an <constant>E_WARNING</constant>
level error if <parameter>size</parameter> is less than 1 or greater than
<constant>PHP_INT_MAX</constant>.
</para>
</refsect1>

<refsect1 role="changelog"><!-- {{{ -->
&reftitle.changelog;
<para>
<informaltable>
<tgroup cols="2">
<thead>
<row>
<entry>&Version;</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row>
<entry>PHP 8.0.0</entry>
<entry>
A <classname>ValueError</classname> is now thrown if
<parameter>size</parameter> is less than 1 or greater than
<constant>PHP_INT_MAX</constant>.
</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>
</refsect1><!-- }}} -->

</refentry>
<!-- Keep this comment at the end of the file
Local variables:
Expand Down

0 comments on commit 0768cd9

Please sign in to comment.