Commit e516e35b authored by rbultje's avatar rbultje

Cast sample_fmt (as read from bitstream as a 16-bit value) to int16, so that

negative values, e.g. SAMPLE_FMT_NONE (-1), are read correctly also.



git-svn-id: file:///var/local/repositories/ffmpeg/trunk@22585 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent c3e102cf
...@@ -354,7 +354,7 @@ static int ffm_read_header(AVFormatContext *s, AVFormatParameters *ap) ...@@ -354,7 +354,7 @@ static int ffm_read_header(AVFormatContext *s, AVFormatParameters *ap)
codec->sample_rate = get_be32(pb); codec->sample_rate = get_be32(pb);
codec->channels = get_le16(pb); codec->channels = get_le16(pb);
codec->frame_size = get_le16(pb); codec->frame_size = get_le16(pb);
codec->sample_fmt = get_le16(pb); codec->sample_fmt = (int16_t) get_le16(pb);
break; break;
default: default:
goto fail; goto fail;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment