[Bug 15699] New: Winecfg crashes if no audio driver is present

wine-bugs at winehq.org wine-bugs at winehq.org
Tue Oct 21 03:38:49 CDT 2008


http://bugs.winehq.org/show_bug.cgi?id=15699

           Summary: Winecfg crashes if no audio driver is present
           Product: Wine
           Version: 1.1.6
          Platform: PC
        OS/Version: Solaris
            Status: NEW
          Keywords: patch, source
          Severity: normal
          Priority: P2
         Component: programs
        AssignedTo: wine-bugs at winehq.org
        ReportedBy: austinenglish at gmail.com
                CC: austinenglish at gmail.com


Based off bug 15264,

Still messing around with OpenSolaris. ./configure now only complains about
capi and ldap, so sound should be fine. config.log shows HAVE_ESD defined to 1.

$ ./wine winecfg

Works fine, but click the Audio tab, and all hell breaks loose:
wine: Unhandled page fault on read access to 0x00000000 at address 7f7907c4
(thread 0009), starting debugger...
Unhandled exception: page fault on read access to 0x00000000 in 32-bit code
(0x7f7907c4)
...
Backtrace:
=>1 0x7f7907cd initAudioDlg+0x9c(hDlg=1004a)
[/export/home/austin/wine-git/programs/winecfg/audio.c:637] in winecfg
(0x7f75ec88)
  2 0x7f791327 AudioDlgProc+0x6de(hDlg=1004a, uMsg=272, wParam=0,
lParam=2143778864) [/export/home/austin/wine-git/programs/winecfg/audio.c:849]
in winecfg (0x7f75ed98)


This patch gets around it, but doesn't seem right to me:
diff --git a/programs/winecfg/audio.c b/programs/winecfg/audio.c
index 3ce0e25..34d1f32 100644
--- a/programs/winecfg/audio.c
+++ b/programs/winecfg/audio.c
@@ -633,8 +633,11 @@ static void initAudioDlg (HWND hDlg)
     if (buf == NULL)
     {
         /* select first available driver */
-        if (*loadedAudioDrv->szDriver)
-            selectDriver(hDlg, loadedAudioDrv->szDriver);
+        if (loadedAudioDrv->szDriver) {
+            if (*loadedAudioDrv->szDriver)
+                selectDriver(hDlg, loadedAudioDrv->szDriver);
+        }
+
     }
     else /* make a local copy of the current registry setting */
         strcpy(curAudioDriver, buf);


-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
Do not reply to this email, post in Bugzilla using the
above URL to reply.
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the wine-bugs mailing list