Skip to content

ext/pdo_odbc: Require non-empty string when building string buffer#21652

Merged
NattyNarwhal merged 1 commit intophp:PHP-8.4from
NattyNarwhal:gh-21534
Apr 13, 2026
Merged

ext/pdo_odbc: Require non-empty string when building string buffer#21652
NattyNarwhal merged 1 commit intophp:PHP-8.4from
NattyNarwhal:gh-21534

Conversation

@NattyNarwhal
Copy link
Copy Markdown
Member

A buggy driver could do this and get PDO_ODBC stuck in this loop. Require a non-empty string, so an empty one breaks like the SQL_NO_DATA case.

Fixes GH-21534

A buggy driver could do this and get PDO_ODBC stuck in this loop.
Require a non-empty string, so an empty one breaks like the SQL_NO_DATA
case.

Fixes phpGH-21534
@NattyNarwhal
Copy link
Copy Markdown
Member Author

Merging because OK from Saki in comment on linked issue; working with Db2i driver in user testing and with SQL Server in CI

@NattyNarwhal NattyNarwhal merged commit 9b6f83e into php:PHP-8.4 Apr 13, 2026
19 checks passed
NattyNarwhal added a commit that referenced this pull request Apr 13, 2026
* PHP-8.4:
  ext/pdo_odbc: Require non-empty string when building string buffer (#21652)
NattyNarwhal added a commit that referenced this pull request Apr 13, 2026
* PHP-8.5:
  ext/pdo_odbc: Require non-empty string when building string buffer (#21652)
@SakiTakamachi
Copy link
Copy Markdown
Member

Yes, I was feeling unwell, so my response was delayed. LGTM!

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