Print Page | Close Window

Major Bug in CXTPAccessible::AccessibleObjectFromW

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=6816
Printed Date: 29 April 2024 at 2:53am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Major Bug in CXTPAccessible::AccessibleObjectFromW
Posted By: mber
Subject: Major Bug in CXTPAccessible::AccessibleObjectFromW
Date Posted: 09 April 2007 at 6:55am
Hello ...
 
Problem
The following bug causes an access violation (crash on Windows Vista) on all systems where an accessibility client (e.g. Narrator from MS Windows, HP Credential Manager for ProtectTools and many others) is active.
 
Reproduce
To reproduce the problem
1. Start Narrator (Accessories->Accessibility->Narrator).
2. Start a sample application from Codejock (e.g. Gallery Sample).
3. Select a menu item (e.g. File).
4. Move mouse to another menu item (e.g. Edit)
=> Crash in oleacct.dll on Windows Vista, Access Violation (Cannot read memory at address ...) on all others.
 
Fix
Version: 10.4.2
File: XTPSystemHelper.cpp
 
HRESULT CXTPAccessible::AccessibleObjectFromWindow(HWND hwnd, DWORD dwId, REFIID riid, void** ppvObject)
{
 if (!m_modOleAcc)
 {
  m_modOleAcc.LoadLibrary(_T("oleacc.dll"));
 }
 if (m_pAccessibleObjectFromWindow == 0)
 {
BUG:
  m_modOleAcc.GetProcAddress(
   (FARPROC*)&m_pNotifyWinEvent, "AccessibleObjectFromWindow");
FIX:
  m_modOleAcc.GetProcAddress(
   (FARPROC*)&m_pAccessibleObjectFromWindow, "AccessibleObjectFromWindow");

 }
 if (m_pAccessibleObjectFromWindow)
 {
  return m_pAccessibleObjectFromWindow(hwnd, dwId, riid, ppvObject);
 }
 return E_FAIL;
}
 
Regards,
-Mat
SmartFTP
http://www.smartftp.com - http://www.smartftp.com



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net