aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortinyalsa <simonwilson@google.com>2012-05-15 16:46:41 -0700
committertinyalsa <simonwilson@google.com>2012-05-15 16:46:41 -0700
commitfcebcad9913c86acd16ca21849bcea16a153f6e5 (patch)
treefcc86128ce74a2b17d2ba8ab4bfa29509adcaa47
parentb6db70a16026bfc226a200a4382d04e2d15d84a1 (diff)
parentfba29e6b27645c6b1a450be384d878b8ea38c592 (diff)
Merge pull request #13 from mesak82/tinycap_header
tinycap: Fix byte_rate and block_align values
-rw-r--r--tinycap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tinycap.c b/tinycap.c
index dcc238c..d563309 100644
--- a/tinycap.c
+++ b/tinycap.c
@@ -136,9 +136,9 @@ int main(int argc, char **argv)
header.audio_format = FORMAT_PCM;
header.num_channels = channels;
header.sample_rate = rate;
+ header.bits_per_sample = bits;
header.byte_rate = (header.bits_per_sample / 8) * channels * rate;
header.block_align = channels * (header.bits_per_sample / 8);
- header.bits_per_sample = bits;
header.data_id = ID_DATA;
/* leave enough room for header */