This is an automated email from the ASF dual-hosted git repository. leginee pushed a commit to branch trunk-dbaccess-wizard-fixes in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit 02d7554dd3a90f6bb7c5bdcddd4b573a1fed6810 Author: Peter Kovacs <[email protected]> AuthorDate: Sat Aug 15 10:20:08 2026 +0200 sdbc_hsqldb: stop preloading two libraries that have not existed for years NativeLibraries.load() preloads native libraries on Windows before System.loadLibrary("hsqldb"). Two of the names are dead: msvcr71 the Visual Studio 2003 C runtime. AOO has not built against it for a very long time, and the CRT is in any case resolved through the side-by-side assembly named in each library's manifest, not by preloading. Removed rather than renamed. dbtoolsmi "dbtools" with the DLLPOSTFIX of a much older Windows platform set appended. DLLPOSTFIX is empty in every wntmsci*.mk, so the library has been plain dbtools.dll for as long as those files have looked the way they do. Corrected to "dbtools". Both therefore always throw UnsatisfiedLinkError, which loadLibrary() below swallows when the classloader lookup also comes up empty -- so this has been completely invisible, which is presumably why it survived. The preloads are belt and braces anyway: in the office hsqldb.dll is already loaded as a UNO component with its imports resolved, so nothing depended on them succeeding. Not a behaviour change beyond removing two failing LoadLibrary calls per connection. Left alone deliberately: uwinapi and sal3, which do exist and do load. (LibreOffice dropped uwinapi from this same list, but only because they removed that library outright; both stale names are still present there too.) Co-Authored-By: Claude Opus 5 <[email protected]> --- .../java/com/sun/star/sdbcx/comp/hsqldb/NativeLibraries.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/main/connectivity/java/sdbc_hsqldb/src/main/java/com/sun/star/sdbcx/comp/hsqldb/NativeLibraries.java b/main/connectivity/java/sdbc_hsqldb/src/main/java/com/sun/star/sdbcx/comp/hsqldb/NativeLibraries.java index f1ae6e9d57..23814c78d3 100644 --- a/main/connectivity/java/sdbc_hsqldb/src/main/java/com/sun/star/sdbcx/comp/hsqldb/NativeLibraries.java +++ b/main/connectivity/java/sdbc_hsqldb/src/main/java/com/sun/star/sdbcx/comp/hsqldb/NativeLibraries.java @@ -30,10 +30,16 @@ import java.net.URLClassLoader; final class NativeLibraries { public static void load() { if (System.getProperty( "os.name" ).startsWith("Windows")) { - loadLibrary("msvcr71"); + // No CRT is preloaded: it is resolved through the side-by-side + // assembly named in each library's manifest. The msvcr71 that used + // to be listed here is the Visual Studio 2003 runtime, which has not + // been the one AOO builds against for a very long time. loadLibrary("uwinapi"); loadLibrary("sal3"); - loadLibrary("dbtoolsmi"); + // "dbtoolsmi" until now, which appends the DLLPOSTFIX of a much older + // Windows platform set. DLLPOSTFIX is empty in every wntmsci*.mk, so + // the library has been dbtools.dll for as long as those have existed. + loadLibrary("dbtools"); } loadLibrary("hsqldb"); }
