diff options
author | Taylor Holberton <tay10r@protonmail.com> | 2020-04-20 20:23:25 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-20 20:23:25 -0700 |
commit | 67cca676121ec99bd31caf9e70e888280b9399c8 (patch) | |
tree | 9433f9639378e460c829f86aa737388e4ca633f8 /src/pcm_hw.c | |
parent | 2feb925cedc25a761d35e32edc37a54a11ebad1d (diff) | |
parent | 859adb2d2f4cd38d264d018404da5b8d09fd854a (diff) |
Merge pull request #151 from mgaio/fix/pcm_open_failure
pcm_hw_close: avoid SIGSEGV when pcm_hw_open fail
Diffstat (limited to 'src/pcm_hw.c')
-rw-r--r-- | src/pcm_hw.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/pcm_hw.c b/src/pcm_hw.c index 1e67e9b..e25cdae 100644 --- a/src/pcm_hw.c +++ b/src/pcm_hw.c @@ -97,6 +97,7 @@ static int pcm_hw_open(unsigned int card, unsigned int device, fd = open(fn, O_RDWR); if (fd < 0) { + free(hw_data); return fd; } |