php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #80560 Strings containing only a base prefix return 0 object
Submitted: 2020-12-29 01:24 UTC Modified: -
From: girgias@php.net Assigned:
Status: Closed Package: GNU MP related
PHP Version: 7.4.14RC1 OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: girgias@php.net
New email:
PHP Version: OS:

 

 [2020-12-29 01:24 UTC] girgias@php.net
Description:
------------
This came about in the review of the explicit octal literal RFC implementation.

It turns out that GMP extension will accept the following strings "0B", "0b", "0X", and "0x" as valid strings if, and only if, no base or base = 0 is provided.

Test script:
---------------
https://3v4l.org/ArU7r


Patches

Pull Requests

Pull requests:

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-12-29 01:37 UTC] girgias@php.net
The following pull request has been associated:

Patch Name: Fix Bug #80560: Strings containing only a base prefix return 0 object
On GitHub:  https://github.com/php/php-src/pull/6549
Patch:      https://github.com/php/php-src/pull/6549.patch
 [2020-12-30 11:51 UTC] cmb@php.net
Automatic comment on behalf of girgias
Revision: http://git.php.net/?p=php-src.git;a=commit;h=abecaab09f8d39b5d2d6bc336e91595aae0d5a91
Log: Fix #80560: Strings containing only a base prefix return 0 object
 [2020-12-30 11:51 UTC] cmb@php.net
-Status: Open +Status: Closed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 21 13:01:29 2024 UTC