libspark/audio_mixer: don't try to free() stack-allocated snd_mixer_selem_id

Origin commit data
------------------
Branch: master
Commit: 86e70db211
Author: martii <m4rtii@gmx.de>
Date: 2013-08-14 (Wed, 14 Aug 2013)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
martii
2013-08-14 20:48:09 +02:00
parent 823633f7b2
commit de48f2efe6
2 changed files with 1 additions and 4 deletions

View File

@@ -20,7 +20,7 @@
#include <audio_mixer.h>
mixerVolume::mixerVolume(const char *name, const char *card, long volume) {
sid = NULL;
snd_mixer_selem_id_t *sid = NULL;
elem = NULL;
handle = NULL;
min = 0;
@@ -58,8 +58,6 @@ mixerVolume::~mixerVolume()
{
if (handle)
snd_mixer_close(handle);
if (sid)
snd_mixer_selem_id_free(sid);
}
bool mixerVolume::setVolume(long volume) {

View File

@@ -27,7 +27,6 @@ class mixerVolume
long min, max;
snd_mixer_t *handle;
snd_mixer_elem_t* elem;
snd_mixer_selem_id_t *sid;
public:
mixerVolume(const char *selem_name, const char *Card, long volume = -1);
~mixerVolume(void);