]> git.proxmox.com Git - mirror_qemu.git/commit
libdecnumber: Fix decNumberSetBCD
authorTom Musta <tommusta@gmail.com>
Mon, 21 Apr 2014 20:54:55 +0000 (15:54 -0500)
committerAlexander Graf <agraf@suse.de>
Mon, 16 Jun 2014 11:24:29 +0000 (13:24 +0200)
commit0a322e7e7cc25267fb4f900d4bc193a134cd72fe
tree3d3042fe85e05338699183d612d1843aec1fcf4f
parent79af3572250352c5eeacdd813b57ad5ba748654c
libdecnumber: Fix decNumberSetBCD

Fix a simple bug in the decNumberSetBCD() function.  This function
encodes a decNumber with "n" BCD digits.  The original code erroneously
computed the number of declets from the dn argument, which is the output
decNumber value, and hence may contain garbage.  Instead, the input "n"
value is used.

Signed-off-by: Tom Musta <tommusta@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
libdecnumber/decNumber.c