Skip to content

ext/readline: Fix non-ASCII pending input in readline_info() - #25285

Merged
LamentXU123 merged 1 commit into
php:PHP-8.4from
LamentXU123:readline-fix
Nov 7, 2026
Merged

LamentXU123 merged 1 commit into
php:PHP-8.4from
LamentXU123:readline-fix

Conversation

@LamentXU123

@LamentXU123 LamentXU123 commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

In some platform char is signed. setting pending_input to a non-ASCII byte returns a negative value.

<?php
readline_info('pending_input', "\xff");

\xff might become EOF (-1)

@LamentXU123
LamentXU123 merged commit a93d24c into php:PHP-8.4 Nov 7, 2026
18 checks passed
LamentXU123 added a commit that referenced this pull request Nov 7, 2026
* PHP-8.6:
  ext/readline: Fix non-ASCII pending input in readline_info() (#25285)
devnexen pushed a commit to devnexen/php-src that referenced this pull request Nov 7, 2026
* PHP-8.4:
  ext/readline: Fix non-ASCII pending input in readline_info() (php#25285)
devnexen pushed a commit to devnexen/php-src that referenced this pull request Nov 7, 2026
* PHP-8.5:
  ext/readline: Fix non-ASCII pending input in readline_info() (php#25285)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants