From b8b755758cfa1e297332e5edf8e9e166ddf327ac Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Wed, 30 Sep 2009 01:13:18 +0000 Subject: Initialize dwOSVersionInfoSize before calling GetVersionEx(). Subversion-branch: /branches/opl-branch Subversion-revision: 1697 --- opl/opl_win9x.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'opl') diff --git a/opl/opl_win9x.c b/opl/opl_win9x.c index 04555760..ff527b3e 100644 --- a/opl/opl_win9x.c +++ b/opl/opl_win9x.c @@ -96,6 +96,9 @@ static int OPL_Win9x_Init(unsigned int port_base) // Check that this is a Windows 9x series OS: + memset(&version_info, 0, sizeof(version_info)); + version_info.dwOSVersionInfoSize = sizeof(version_info); + GetVersionEx(&version_info); if (version_info.dwPlatformId == 1) -- cgit v1.2.3