mirror of
https://github.com/alsa-project/alsa-tools.git
synced 2026-02-04 04:06:24 -05:00
hdspmixer: fix null pointer dereference in HDSPMixerWindow:handler_cb
Closes: https://github.com/alsa-project/alsa-tools/pull/42 Signed-off-by: Christian Heldt <snaut@tutanota.com> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
4b4886b5f9
commit
a3fd2c53b6
1 changed files with 7 additions and 7 deletions
|
|
@ -274,15 +274,15 @@ static int handler_cb(int event)
|
||||||
{
|
{
|
||||||
HDSPMixerWindow *w = NULL;
|
HDSPMixerWindow *w = NULL;
|
||||||
Fl_Window *fl_win = Fl::first_window();
|
Fl_Window *fl_win = Fl::first_window();
|
||||||
while (1) {
|
while (fl_win) {
|
||||||
if (fl_win->label()) {
|
if (fl_win->label()) {
|
||||||
if (strncmp("HDSPMixer", fl_win->label(), 9) == 0) {
|
if (strncmp("HDSPMixer", fl_win->label(), 9) == 0) {
|
||||||
w = (HDSPMixerWindow *)fl_win;
|
w = (HDSPMixerWindow *)fl_win;
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
fl_win = Fl::next_window(fl_win);
|
||||||
}
|
}
|
||||||
if ((fl_win = Fl::next_window(fl_win))) return 0;
|
|
||||||
}
|
|
||||||
if (!w) return 0;
|
if (!w) return 0;
|
||||||
int key = Fl::event_key();
|
int key = Fl::event_key();
|
||||||
switch (event) {
|
switch (event) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue