summaryrefslogtreecommitdiff
path: root/ext/standard
diff options
context:
space:
mode:
authorAndrei Zmievski <andrei@php.net>2000-05-17 12:51:37 +0000
committerAndrei Zmievski <andrei@php.net>2000-05-17 12:51:37 +0000
commite2e636348803183b0cecf33dad51da0df24a34b5 (patch)
treeee5633b43fa3149e2ae9199e57fec06e22c53065 /ext/standard
parent08ff225a467c05c34a38aceccdb67fe1411fd185 (diff)
downloadphp-git-e2e636348803183b0cecf33dad51da0df24a34b5.tar.gz
Let's cast it.
Diffstat (limited to 'ext/standard')
-rw-r--r--ext/standard/math.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/standard/math.c b/ext/standard/math.c
index 5671c9426a..c78ff5633c 100644
--- a/ext/standard/math.c
+++ b/ext/standard/math.c
@@ -132,7 +132,8 @@ PHP_FUNCTION(round)
/* break omitted intentionally */
case IS_DOUBLE:
- return_val = (Z_TYPE_PP(value) == IS_LONG) ? Z_LVAL_PP(value) : Z_DVAL_PP(value);
+ return_val = (Z_TYPE_PP(value) == IS_LONG) ?
+ (double)Z_LVAL_PP(value) : Z_DVAL_PP(value);
f = pow(10.0, places);