aboutsummaryrefslogtreecommitdiff
path: root/boca-1.5.1/src/hex.php
diff options
context:
space:
mode:
Diffstat (limited to 'boca-1.5.1/src/hex.php')
-rw-r--r--boca-1.5.1/src/hex.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/boca-1.5.1/src/hex.php b/boca-1.5.1/src/hex.php
index 0d80b1d..4fa4c16 100644
--- a/boca-1.5.1/src/hex.php
+++ b/boca-1.5.1/src/hex.php
@@ -141,8 +141,8 @@ function bighexsub ($hex1, $hex2) {
$r += 16;
$sobra = 1;
} else $sobra = 0;
-
- $resultado = dechex($r) . $resultado;
+ if($x > 0 || dechex($r) != '0')
+ $resultado = dechex($r) . $resultado;
}
return $sinal . $resultado;
}