diff options
author | Simon Wilson <ksattic@gmail.com> | 2015-09-15 10:57:07 -0700 |
---|---|---|
committer | Simon Wilson <ksattic@gmail.com> | 2015-09-15 10:57:07 -0700 |
commit | ab1cecf5d3d3f75e4826c6028774a2a415fc6653 (patch) | |
tree | 1588c3c74740d7d64286bae5148f6cac921454b6 | |
parent | 4a31e4c1f0a27fce50fdbae4dc7b7fb8bac7cc5e (diff) | |
parent | e4f8a5b2859001bc8765435539c64bdf602b466e (diff) |
Merge pull request #62 from gkasten/pcm_config_zero
initialize pcm_config to zero
-rw-r--r-- | tinycap.c | 1 | ||||
-rw-r--r-- | tinyplay.c | 1 |
2 files changed, 2 insertions, 0 deletions
@@ -206,6 +206,7 @@ unsigned int capture_sample(FILE *file, unsigned int card, unsigned int device, unsigned int size; unsigned int bytes_read = 0; + memset(&config, 0, sizeof(config)); config.channels = channels; config.rate = rate; config.period_size = period_size; @@ -218,6 +218,7 @@ void play_sample(FILE *file, unsigned int card, unsigned int device, unsigned in int size; int num_read; + memset(&config, 0, sizeof(config)); config.channels = channels; config.rate = rate; config.period_size = period_size; |