-            SDL_AudioDriverName(driver, 256);                    
-            wxLogTrace(_T("sound"), _T("opened audio, driver '%s'"),
+#if SDL_MAJOR_VERSION == 1
+            SDL_AudioDriverName(driver, 256);
+#elif SDL_MAJOR_VERSION > 1            
+            strncpy(driver, SDL_GetCurrentAudioDriver(), 256);
+#endif
+            wxLogTrace(wxT("sound"), wxT("opened audio, driver '%s'"),