Browse Source

Merge pull request #669 from BeamNG/fix_ALDeviceList_GetDeviceVersion

Fix ALDeviceList::GetDeviceVersion incorrect check of valid pointer.
Thomas Fischer 11 years ago
parent
commit
8c00e79ded
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Engine/source/sfx/openal/aldlist.cpp

+ 2 - 2
Engine/source/sfx/openal/aldlist.cpp

@@ -161,9 +161,9 @@ const char *ALDeviceList::GetDeviceName(int index)
 void ALDeviceList::GetDeviceVersion(int index, int *major, int *minor)
 void ALDeviceList::GetDeviceVersion(int index, int *major, int *minor)
 {
 {
 	if (index < GetNumDevices()) {
 	if (index < GetNumDevices()) {
-		if (*major)
+		if (major)
 			*major = vDeviceInfo[index].iMajorVersion;
 			*major = vDeviceInfo[index].iMajorVersion;
-		if (*minor)
+		if (minor)
 			*minor = vDeviceInfo[index].iMinorVersion;
 			*minor = vDeviceInfo[index].iMinorVersion;
 	}
 	}
 	return;
 	return;