From:             [EMAIL PROTECTED]
Operating system: Linux 2.4.18 (Red Hat 7.3)
PHP version:      4.2.3
PHP Bug Type:     Java related
Bug description:  Random casting results when Java ext is used

PHP 4.2.3 compiled with Sun JDK 1.3.1

Script like this:

$var_a="10.10";
echo "A: ";
var_dump($var_a);
$var_b=(float)$var_a;
echo "A: ";
var_dump($var_b);

Normaly gives this result:
A: string(5) "10.10" B: float(10.1)


But when in the same file we create java object:

$var_a="10.10";
echo "A: ";
var_dump($var_a);
$var_b=(float)$var_a;
echo "A: ";
var_dump($var_b);
$system = new Java('java.lang.System');

Output can be:
A: string(5) "10.10" B: float(10)
or like before:
A: string(5) "10.10" B: float(10.1)

Strange.

Grzegorz Kryza




-- 
Edit bug report at http://bugs.php.net/?id=19961&edit=1
-- 
Try a CVS snapshot:         http://bugs.php.net/fix.php?id=19961&r=trysnapshot
Fixed in CVS:               http://bugs.php.net/fix.php?id=19961&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=19961&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=19961&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=19961&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=19961&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=19961&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=19961&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=19961&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=19961&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=19961&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=19961&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=19961&r=isapi

Reply via email to