diff options
author | Stefano Sabatini <stefasab@gmail.com> | 2012-01-19 01:34:30 +0100 |
---|---|---|
committer | Stefano Sabatini <stefasab@gmail.com> | 2012-01-20 13:27:52 +0100 |
commit | 4601ad769df9a5c4e51a06a75a23c1f8f39595eb (patch) | |
tree | c619f429b95cbadf7cdd62e70d6e8667a154d7df | |
parent | eef4b70450b5ed57a5c57a719d31b8ca14532bc9 (diff) | |
download | ffmpeg-streaming-4601ad769df9a5c4e51a06a75a23c1f8f39595eb.zip ffmpeg-streaming-4601ad769df9a5c4e51a06a75a23c1f8f39595eb.tar.gz |
ffprobe: fix value_string() prefix printing for values with negative logarithm
The index for the binary_unit_prefixes array is expected to be positive,
so avoid to use negative indexes for accessing it.
-rw-r--r-- | ffprobe.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -106,7 +106,7 @@ static char *value_string(char *buf, int buf_size, struct unit_value uv) const char *prefix_string = ""; int l; - if (use_value_prefix) { + if (use_value_prefix && vald > 1) { long long int index; if (uv.unit == unit_byte_str && use_byte_value_binary_prefix) { |