php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #9151 base_convert interprets letters w,x,y,z as 0
Submitted: 2001-02-07 11:02 UTC Modified: 2001-02-14 06:36 UTC
From: gherson at snet dot net Assigned:
Status: Not a bug Package: Math related
PHP Version: 4.0.4 OS: Linux 2.2 - Redhat 6.2
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: gherson at snet dot net
New email:
PHP Version: OS:

 

 [2001-02-07 11:02 UTC] gherson at snet dot net
Hi.  Base_convert interprets letters w,x,y, and z to be zero but should handle letters up to z: "Digits in numbers with a base higher than 10 will be represented with the letters a-z, with a meaning 10, b meaning 11 and z meaning 35." -- http://www.php.net/manual/en/function.base-convert.php

Shows problem:
$base32 = 'x';           // a-v ok, w-z=0
$base10 = base_convert($base32, 32, 10);
echo "base10: $base10\n";

My configure line:
./configure --with-cybercash=/usr/local/bin/mck-3.3.0-i586-pc-linux-gnulibc2.1 --with-pgsql=/var/lib/pgsql --with-apxs

thanks,
George 

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-02-07 11:12 UTC] gherson at snet dot net
Sorry, stupid mistake on my part.  Pls ignore
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Oct 31 23:01:28 2024 UTC