diff options
author | Angela Stegmaier | 2014-04-15 15:53:19 -0500 |
---|---|---|
committer | Gerrit Code Review | 2014-06-03 14:54:49 -0500 |
commit | fe4561a100a8a0205d1bfab0bd85da4da03942fa (patch) | |
tree | f8f1c647bfff181597ba4bcf67e1f15bd128d66d | |
parent | 3d3ef412e122bf8ab706153a657d3b26ec74e1fd (diff) | |
download | device-ti-jacinto6evm-fe4561a100a8a0205d1bfab0bd85da4da03942fa.tar.gz device-ti-jacinto6evm-fe4561a100a8a0205d1bfab0bd85da4da03942fa.tar.xz device-ti-jacinto6evm-fe4561a100a8a0205d1bfab0bd85da4da03942fa.zip |
audio: Legacy: Initialize Variables to NULL
If uninitialized, then a crash may result if they were not
successfully allocated during the constructor and then
the destructor runs.
Change-Id: Iad15e558fe6ba9b42aab482511cd30c1476f0f18
Signed-off-by: Angela Stegmaier <a0866189@ti.com>
-rw-r--r-- | audio/legacy/audio_hw.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/audio/legacy/audio_hw.c b/audio/legacy/audio_hw.c index cef97c5..1ce01f5 100644 --- a/audio/legacy/audio_hw.c +++ b/audio/legacy/audio_hw.c | |||
@@ -1143,6 +1143,8 @@ static int adev_open_input_stream(struct audio_hw_device *dev, | |||
1143 | in->requested_channels = popcount(config->channel_mask); | 1143 | in->requested_channels = popcount(config->channel_mask); |
1144 | in->hw_frame_size = in->config.channels * sizeof(int16_t); | 1144 | in->hw_frame_size = in->config.channels * sizeof(int16_t); |
1145 | in->remix = NULL; | 1145 | in->remix = NULL; |
1146 | in->resampler = NULL; | ||
1147 | in->buffer = NULL; | ||
1146 | adev->in = in; | 1148 | adev->in = in; |
1147 | 1149 | ||
1148 | /* in-place stereo-to-mono remix since capture stream is stereo */ | 1150 | /* in-place stereo-to-mono remix since capture stream is stereo */ |