From:             
Operating system: Solaris10 on sparc
PHP version:      5.3.3
Package:          MySQLi related
Bug Type:         Bug
Bug description:mysql_stmt_attr_[gs]et arg. points to incorrect type

Description:
------------
The 3. argument to mysql_stmt_attr_[gs]et() should be a pointer to my_bool
or ulong depending on the value of its 2. arg. :-(  As of now the code
always pass pointers to either my_bool or ulong, causing a bus error or
incorrect value to be retrieved on a big-endian system like solaris/sparc.



A patch that fixes and tests this problem is coming.  Using the patch, the
ext/mysqli/tests/mysqli_stmt_attr_[gs]et.phpt tests succeed for me on
solaris10/sparc, solaris10/x86_64 and redhat4/x86_64, without it they fail
on solaris10/sparc.



Btw, tested using mysql 5.1.35.  According to the mysql doc. the argument
changed from an uint* to a my_bool* in mysql 5.1.7.




-- 
Edit bug report at http://bugs.php.net/bug.php?id=52686&edit=1
-- 
Try a snapshot (PHP 5.2):            
http://bugs.php.net/fix.php?id=52686&r=trysnapshot52
Try a snapshot (PHP 5.3):            
http://bugs.php.net/fix.php?id=52686&r=trysnapshot53
Try a snapshot (trunk):              
http://bugs.php.net/fix.php?id=52686&r=trysnapshottrunk
Fixed in SVN:                        
http://bugs.php.net/fix.php?id=52686&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=52686&r=needdocs
Fixed in release:                    
http://bugs.php.net/fix.php?id=52686&r=alreadyfixed
Need backtrace:                      
http://bugs.php.net/fix.php?id=52686&r=needtrace
Need Reproduce Script:               
http://bugs.php.net/fix.php?id=52686&r=needscript
Try newer version:                   
http://bugs.php.net/fix.php?id=52686&r=oldversion
Not developer issue:                 
http://bugs.php.net/fix.php?id=52686&r=support
Expected behavior:                   
http://bugs.php.net/fix.php?id=52686&r=notwrong
Not enough info:                     
http://bugs.php.net/fix.php?id=52686&r=notenoughinfo
Submitted twice:                     
http://bugs.php.net/fix.php?id=52686&r=submittedtwice
register_globals:                    
http://bugs.php.net/fix.php?id=52686&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=52686&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=52686&r=dst
IIS Stability:                       
http://bugs.php.net/fix.php?id=52686&r=isapi
Install GNU Sed:                     
http://bugs.php.net/fix.php?id=52686&r=gnused
Floating point limitations:          
http://bugs.php.net/fix.php?id=52686&r=float
No Zend Extensions:                  
http://bugs.php.net/fix.php?id=52686&r=nozend
MySQL Configuration Error:           
http://bugs.php.net/fix.php?id=52686&r=mysqlcfg

Reply via email to