File: alc_error.patch

package info (click to toggle)
funguloids 1.06-16
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 21,348 kB
  • sloc: cpp: 5,081; ansic: 3,285; python: 207; makefile: 154
file content (22 lines) | stat: -rw-r--r-- 941 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
Author: Andres Mejia <mcitadel@gmail.com>
Description: Check ALC errors instead of AL errors.
Forwarded: http://funguloids.sourceforge.net/files/funguloids-patches.tar.bz2
--- a/src/openalsoundsystem.cpp
+++ b/src/openalsoundsystem.cpp
@@ -266,14 +266,14 @@
 
 	int attributes[] = { 0 };
 	mContext = alcCreateContext(mDevice, attributes);
-	if ( (err = alGetError()) != AL_NO_ERROR) {
+	if ( (err = alcGetError(mDevice)) != ALC_NO_ERROR) {
 		LogManager::getSingleton().logMessage("OpanAL: error creating context: " + lastALError(err) );
 		return 1;
 	}
 //	check_alc_error("Couldn't create audio context: ");
 	alcMakeContextCurrent(mContext);
 //	check_alc_error("Couldn't select audio context: ");
-	if ( (err = alGetError()) != AL_NO_ERROR) {
+	if ( (err = alcGetError(mDevice)) != ALC_NO_ERROR) {
 		LogManager::getSingleton().logMessage("OpanAL: error making context current: " + lastALError(err) );
 		return 2;
 	}