Fixed bug in BigDecimal/BigInteger serialization.