Fix print_dB() with a minus value

Fix print_dB() with a minus dB value.
This commit is contained in:
Takashi Iwai 2006-07-06 19:26:31 +02:00
parent 33319eb4ed
commit dedc292efa

View file

@ -389,7 +389,7 @@ static void print_spaces(unsigned int spaces)
static void print_dB(int dB)
{
printf("%i.%02idB", dB / 100, dB % 100);
printf("%i.%02idB", dB / 100, (dB < 0 ? -dB : dB) % 100);
}
static void decode_tlv(unsigned int spaces, unsigned int *tlv, unsigned int tlv_size)