On Sat, 29 Apr 2023 19:26:00 GMT, Julian Waters <[email protected]> wrote:
> In windowsaccessbridge(-64).dll the following methods are exported in a def
> file to C API which in turn call their real implementation, which are
> instance methods of the class WinAccessBridge:
>
> addJavaEventNotification
> removeJavaEventNotification
> addAccessibilityEventNotification
> removeAccessibilityEventNotification
>
>
> However, they are nowhere to be seen in the actual C interface, in
> AccessBridgeWindowsEntryPoints.cpp. Your guess is as good as mine as to how
> on earth MSVC is still capable of compiling and linking this without any
> errors whatsoever, but in any case, this is a severe oversight and should be
> properly defined in the C API lest this happy accident within MSVC is fixed
> by Microsoft in the future
FWIW, this is what dumpbin displays for these entries:
1 2 0000351C addAccessibilityEventNotification =
?addAccessibilityEventNotification@WinAccessBridge@@QEAAX_J@Z (public: void
__cdecl WinAccessBridge::addAccessibilityEventNotification(__int64))
2 4 00003628 addJavaEventNotification =
?addJavaEventNotification@WinAccessBridge@@QEAAX_J@Z (public: void __cdecl
WinAccessBridge::addJavaEventNotification(__int64))
3 42 00006D94 removeAccessibilityEventNotification =
?removeAccessibilityEventNotification@WinAccessBridge@@QEAAX_J@Z (public: void
__cdecl WinAccessBridge::removeAccessibilityEventNotification(__int64))
4 44 00006EA0 removeJavaEventNotification =
?removeJavaEventNotification@WinAccessBridge@@QEAAX_J@Z (public: void __cdecl
WinAccessBridge::removeJavaEventNotification(__int64))
There's no way to get a pointer to an instance of `WinAccessBridge` using the
supported interface, and calling these methods with garbage value for `this`
would likely crash.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/13734#issuecomment-1536386059