diff --git a/Source/Core/DolphinWX/src/MemcardManager.h b/Source/Core/DolphinWX/src/MemcardManager.h index e496de4264..f848027769 100644 --- a/Source/Core/DolphinWX/src/MemcardManager.h +++ b/Source/Core/DolphinWX/src/MemcardManager.h @@ -23,6 +23,7 @@ #include #include #include +#include #include "MemoryCards/GCMemcard.h" diff --git a/Source/Plugins/Plugin_DSP_HLE/Src/PCHW/AOSoundStream.cpp b/Source/Plugins/Plugin_DSP_HLE/Src/PCHW/AOSoundStream.cpp index fbdb2eb5ef..3620f1cbc0 100644 --- a/Source/Plugins/Plugin_DSP_HLE/Src/PCHW/AOSoundStream.cpp +++ b/Source/Plugins/Plugin_DSP_HLE/Src/PCHW/AOSoundStream.cpp @@ -55,6 +55,7 @@ namespace AOSound return(false);*/ //if(soundData[0] != 0) + if(!device) ao_play(device, soundData, numSoundBytes); return true; @@ -112,7 +113,7 @@ namespace AOSound device = ao_open_live(default_driver, &format, NULL /* no options */); if (device == NULL) { fprintf(stderr, "Error opening device.\n"); - return 1; + return false; } buf_size = format.bits/8 * format.channels * format.rate; buffer = (char*)calloc(buf_size, sizeof(char)); @@ -121,6 +122,7 @@ namespace AOSound } void AOSound_StopSound() { + free(buffer); ao_close(device); ao_shutdown(); } diff --git a/Source/Plugins/Plugin_VideoOGL/Src/GLInit.cpp b/Source/Plugins/Plugin_VideoOGL/Src/GLInit.cpp index aca83e087a..1d96054e8f 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/GLInit.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/GLInit.cpp @@ -338,6 +338,11 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight ERROR_LOG("glX-Version %d.%d\n", glxMajorVersion, glxMinorVersion); /* create a GLX context */ GLWin.ctx = glXCreateContext(GLWin.dpy, vi, 0, GL_TRUE); + if(!GLWin.ctx) + { + ERROR_LOG("Couldn't Create GLX context.Quit"); + exit(0); // TODO: Don't bring down entire Emu + } /* create a color map */ cmap = XCreateColormap(GLWin.dpy, RootWindow(GLWin.dpy, vi->screen), vi->visual, AllocNone);