xProp(xStorage,UNO_QUERY);
@@ -327,7 +367,7 @@ namespace connectivity
xProp->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OpenMode"))) >>= nMode;
if ( (nMode & ElementModes::WRITE) != ElementModes::WRITE )
{
- aProperties.put( "readonly", ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
+ aProperties.put( "readonly", ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
}
}
@@ -341,11 +381,17 @@ namespace connectivity
try
{
xOrig = xDriver->connect( sConnectURL, aConnectionArgs );
+ }
+ catch(const SQLException& e)
+ {
+ StorageContainer::revokeStorage(sKey,NULL);
+ OSL_UNUSED(e);
+ throw;
}
catch(const Exception& e)
{
StorageContainer::revokeStorage(sKey,NULL);
- (void)e;
+ OSL_UNUSED(e);
throw;
}
diff --git a/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx b/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
index 91da80c0b66..5909c29c6c0 100644
--- a/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
@@ -435,6 +435,8 @@ void write_to_storage_stream_from_buffer( JNIEnv* env, jobject /*obj_this*/, jst
if ( xOut.is() )
{
jbyte *buf = env->GetByteArrayElements(buffer,NULL);
+ OSL_ENSURE(len <= env->GetArrayLength(buffer),"Length is greater than the buffer!");
+
if (JNI_FALSE != env->ExceptionCheck())
{
env->ExceptionClear();
diff --git a/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx b/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
index 1300df1c79d..56607a1ac86 100644
--- a/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
@@ -58,8 +58,8 @@ namespace connectivity
{
try
{
- m_xStream.clear();
- m_xSeek.clear();
+ m_xStream.clear();
+ m_xSeek.clear();
if ( m_xInputStream.is() )
{
m_xInputStream->closeInput();
diff --git a/main/connectivity/source/inc/resource/hsqldb_res.hrc b/main/connectivity/source/inc/resource/hsqldb_res.hrc
index c76ab335194..e3cdec1adb8 100644
--- a/main/connectivity/source/inc/resource/hsqldb_res.hrc
+++ b/main/connectivity/source/inc/resource/hsqldb_res.hrc
@@ -38,5 +38,7 @@
#define STR_NO_TABLENAME ( STR_HSQLDB_BASE + 4 )
#define STR_NO_DOCUMENTUI ( STR_HSQLDB_BASE + 5 )
#define STR_ERROR_NEW_VERSION ( STR_HSQLDB_BASE + 6 )
+#define STR_CONVERT_TO_NEW_VERSION ( STR_HSQLDB_BASE + 7 )
+#define STR_SHUTDOWN_REQUIRED ( STR_HSQLDB_BASE + 8 )
#endif // CONNECTIVITY_RESOURCE_HSQLDB_HRC
diff --git a/main/connectivity/source/resource/conn_shared_res.src b/main/connectivity/source/resource/conn_shared_res.src
index 598e9dfd81e..8fce2a26cbf 100644
--- a/main/connectivity/source/resource/conn_shared_res.src
+++ b/main/connectivity/source/resource/conn_shared_res.src
@@ -633,5 +633,13 @@ String STR_ERROR_NEW_VERSION
{
Text = "The connection could not be established. The database was created by a newer version of %PRODUCTNAME." ;
};
+String STR_CONVERT_TO_NEW_VERSION
+{
+ Text = "The database file is stored in an old version. Do you want to convert into the new version?" ;
+};
+String STR_SHUTDOWN_REQUIRED
+{
+ Text = "The database file was not stored correctly by a previous version of %PRODUCTNAME.\nPlease open the file with Apache OpenOffice 4.1.x, then click the Tables icon and save." ;
+};
// ********************************************************************** EOF
diff --git a/main/dbaccess/source/core/api/KeySet.cxx b/main/dbaccess/source/core/api/KeySet.cxx
index 0d4721a3303..929a5f54823 100644
--- a/main/dbaccess/source/core/api/KeySet.cxx
+++ b/main/dbaccess/source/core/api/KeySet.cxx
@@ -1338,7 +1338,7 @@ sal_Bool OKeySet::previous_checked( sal_Bool i_bFetchRow )
if ( i_bFetchRow )
refreshRow();
}
- return m_aKeyIter != m_aKeyMap.begin();
+ return m_aKeyIter != m_aKeyMap.end() && m_aKeyIter != m_aKeyMap.begin();
}
// -----------------------------------------------------------------------------
sal_Bool SAL_CALL OKeySet::previous( )
diff --git a/main/external_deps.lst b/main/external_deps.lst
index 2f754194b56..b9ec18f3a8c 100644
--- a/main/external_deps.lst
+++ b/main/external_deps.lst
@@ -81,9 +81,9 @@ if (SYSTEM_LIBTEXTCAT != YES)
URL3 = https://software.wise-guys.nl/download/libtextcat-2.2.tar.gz
if (SOLAR_JAVA == TRUE)
- MD5 = 17410483b5b5f267aa18b7e00b65e6e0
- name = hsqldb_1_8_0.zip
- URL1 = https://sourceforge.net/projects/hsqldb/files/hsqldb/hsqldb_1_8_0/hsqldb_1_8_0_10.zip
+ MD5 = 8140e899c4cdf04e31a06743230f8523
+ name = hsqldb-2.5.0.zip
+ URL1 = https://downloads.sourceforge.net/project/hsqldb/hsqldb/hsqldb_2_5/hsqldb-2.5.0.zip
URL2 = $(OOO_EXTRAS)$(MD5)-$(name)
if ( true )
diff --git a/main/hsqldb/makefile.mk b/main/hsqldb/makefile.mk
index 0583bb51c70..8843054009e 100644
--- a/main/hsqldb/makefile.mk
+++ b/main/hsqldb/makefile.mk
@@ -40,30 +40,27 @@ ANT_BUILDFILE=build$/build.xml
.IF "$(SOLAR_JAVA)" != ""
# --- Files --------------------------------------------------------
-TARFILE_NAME=hsqldb_$(HSQLDB_VERSION)
-TARFILE_MD5=17410483b5b5f267aa18b7e00b65e6e0
+TARFILE_NAME=hsqldb-$(HSQLDB_VERSION)
+TARFILE_MD5=8140e899c4cdf04e31a06743230f8523
-TARFILE_ROOTDIR=hsqldb
+TARFILE_ROOTDIR=hsqldb-$(HSQLDB_VERSION)$/hsqldb
CONVERTFILES=build$/build.xml \
- src$/org$/hsqldb$/persist$/HsqlDatabaseProperties.java \
- src$/org$/hsqldb$/Library.java
+ src$/org$/hsqldb$/persist$/HsqlDatabaseProperties.java
-PATCH_FILES=patches$/i121754.patch patches$/script.patch patches$/runfinalizers.patch patches$/text_tables.patch
+PATCH_FILES=patches$/aoo_integration.patch
-# hsqldb's build.xml javac tasks specify no source/target; pin them so bytecode
-# stays Java 8 compatible regardless of the (possibly much newer) build JDK.
JAVAC_SRCTGT=-Dant.build.javac.source=1.8 -Dant.build.javac.target=1.8
.IF "$(JAVACISGCJ)"=="yes"
JAVA_HOME=
.EXPORT : JAVA_HOME
-BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.compiler=gcj $(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) jar
+BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.compiler=gcj $(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) hsqldb
.ELSE
.IF "$(debug)"!=""
-BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.debug="on" $(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) jar
+BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.debug="on" $(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) hsqldb
.ELSE
-BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" $(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) jar
+BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" $(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) hsqldb
.ENDIF
.ENDIF
diff --git a/main/hsqldb/patches/aoo_integration.patch b/main/hsqldb/patches/aoo_integration.patch
new file mode 100644
index 00000000000..02ff348dd2f
--- /dev/null
+++ b/main/hsqldb/patches/aoo_integration.patch
@@ -0,0 +1,160 @@
+--- misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/Logger.java 2019-05-31 10:26:20.000000000 -0500
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/Logger.java 2026-11-06 10:22:37.173757415 -0500
+@@ -62,6 +62,7 @@
+ import org.hsqldb.lib.FileAccess;
+ import org.hsqldb.lib.FileUtil;
+ import org.hsqldb.lib.FrameworkLogger;
++import java.lang.reflect.Constructor;
+ import org.hsqldb.lib.HsqlArrayList;
+ import org.hsqldb.lib.InputStreamInterface;
+ import org.hsqldb.lib.InputStreamWrapper;
+@@ -183,6 +184,26 @@
+ this.database = database;
+ }
+
++ private static FileAccess getFileAccessCustom(Database database) {
++ String fileAccessClassName = database.urlProperties.getProperty("fileaccess_class_name");
++ if (fileAccessClassName != null && !fileAccessClassName.isEmpty()) {
++ try {
++ Class> fileAccessClass = Class.forName(fileAccessClassName);
++ String storageKey = database.urlProperties.getProperty("storage_key");
++ if (storageKey != null) {
++ Constructor> ctor = fileAccessClass.getConstructor(Object.class);
++ return (FileAccess) ctor.newInstance(storageKey);
++ } else {
++ Constructor> ctor = fileAccessClass.getConstructor();
++ return (FileAccess) ctor.newInstance();
++ }
++ } catch (Exception e) {
++ return FileUtil.getFileAccess(database.isFilesInJar());
++ }
++ }
++ return FileUtil.getFileAccess(database.isFilesInJar());
++ }
++
+ /**
+ * Opens the specified Database object's database files and starts up
+ * the logging process.
+@@ -198,7 +219,7 @@
+ boolean hasFileProps = false;
+ boolean hasScript = false;
+
+- fileAccess = FileUtil.getFileAccess(database.isFilesInJar());
++ fileAccess = getFileAccessCustom(database);
+ propIsFileDatabase = database.getType().isFileBased();
+ database.databaseProperties = new HsqlDatabaseProperties(database);
+ propTextAllowFullPath = database.databaseProperties.isPropertyTrue(
+--- misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAFile.java 2019-04-27 08:55:26.000000000 -0500
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAFile.java 2026-11-06 10:22:37.174321115 -0500
+@@ -43,6 +43,8 @@
+ import org.hsqldb.lib.ArrayUtil;
+ import org.hsqldb.lib.HsqlByteArrayInputStream;
+ import org.hsqldb.lib.HsqlByteArrayOutputStream;
++import org.hsqldb.lib.Storage;
++import java.lang.reflect.Constructor;
+
+ /**
+ * This class is a wrapper for a random access file such as that used for
+@@ -93,6 +95,20 @@
+ String name, boolean readonly,
+ int type) throws FileNotFoundException, IOException {
+
++ String storageClassName = database.urlProperties.getProperty("storage_class_name");
++ if (storageClassName != null && !storageClassName.isEmpty()) {
++ try {
++ Class> storageClass = Class.forName(storageClassName);
++ String storageKey = database.urlProperties.getProperty("storage_key");
++ Constructor> ctor = storageClass.getConstructor(
++ String.class, Boolean.class, Object.class);
++ Storage storage = (Storage) ctor.newInstance(
++ name, Boolean.valueOf(readonly), storageKey);
++ return new RAStorageWrapper(storage);
++ } catch (Exception e) {
++ // fall through to default implementation
++ }
++ }
+ if (type == DATA_FILE_JAR) {
+ return new RAFileInJar(name);
+ } else if (type == DATA_FILE_TEXT) {
+@@ -424,6 +440,81 @@
+ }
+ }
+
++ /**
++ * Wrapper that adapts org.hsqldb.lib.Storage to
++ * org.hsqldb.persist.RandomAccessInterface.
++ * Used for OpenOffice.org storage integration.
++ */
++ static class RAStorageWrapper implements RandomAccessInterface {
++ private final Storage storage;
++
++ RAStorageWrapper(Storage storage) {
++ this.storage = storage;
++ }
++
++ public long length() throws IOException {
++ return storage.length();
++ }
++
++ public void seek(long position) throws IOException {
++ storage.seek(position);
++ }
++
++ public long getFilePointer() throws IOException {
++ return storage.getFilePointer();
++ }
++
++ public int read() throws IOException {
++ return storage.read();
++ }
++
++ public void read(byte[] b, int offset, int length) throws IOException {
++ storage.read(b, offset, length);
++ }
++
++ public void write(byte[] b, int offset, int length) throws IOException {
++ storage.write(b, offset, length);
++ }
++
++ public int readInt() throws IOException {
++ return storage.readInt();
++ }
++
++ public void writeInt(int i) throws IOException {
++ storage.writeInt(i);
++ }
++
++ public long readLong() throws IOException {
++ return storage.readLong();
++ }
++
++ public void writeLong(long i) throws IOException {
++ storage.writeLong(i);
++ }
++
++ public void close() throws IOException {
++ storage.close();
++ }
++
++ public boolean isReadOnly() {
++ return storage.isReadOnly();
++ }
++
++ public void synch() {
++ // Storage interface does not have synch, delegate to no-op
++ }
++
++ public boolean ensureLength(long newLength) {
++ // Storage interface does not have ensureLength
++ return true;
++ }
++
++ public boolean setLength(long newLength) {
++ // Storage interface does not have setLength
++ return false;
++ }
++ }
++
+ private void resetPointer() {
+
+ try {
diff --git a/main/hsqldb/patches/i121754.patch b/main/hsqldb/patches/i121754.patch
deleted file mode 100644
index fe3d6fb9e54..00000000000
--- a/main/hsqldb/patches/i121754.patch
+++ /dev/null
@@ -1,430 +0,0 @@
-diff -urbwB ext_sources/hsqldb/build/build.xml ext_sources/hsqldb_1_8_0_11/build/build.xml
---- misc/hsqldb/build/build.xml 2008-06-01 23:56:57.000000000 +0200
-+++ misc/build/hsqldb/build/build.xml 2013-07-05 23:25:40.000000000 +0200
-@@ -1,6 +1,6 @@
-
--
--
-+
-+
-
-
-
-
--
-+
-
-
--
-
-
-@@ -26,7 +26,7 @@
-
-
-
--
-+
-
-
-
-@@ -213,10 +213,11 @@
-
-
-
--
-
-
-+
-
-
-
-@@ -251,6 +252,7 @@
-
-
-+
-
-
-
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Expression.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Expression.java
---- misc/hsqldb/src/org/hsqldb/Expression.java 2008-05-27 17:15:05.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/Expression.java 2013-07-05 23:40:51.000000000 +0200
-@@ -807,6 +807,14 @@
-
- case COUNT :
- buf.append(' ').append(Token.T_COUNT).append('(');
-+
-+ if ("(*)".equals(left)) {
-+ buf.append('*');
-+ } else {
-+ buf.append(left);
-+ }
-+
-+ buf.append(')');
- break;
-
- case SUM :
-@@ -858,11 +866,15 @@
- buf.append(' ').append(Token.T_VAR_SAMP).append('(');
- buf.append(left).append(')');
- break;
-- }
-
-+ default :
- throw Trace.error(Trace.EXPRESSION_NOT_SUPPORTED);
- }
-
-+ // changes used in OpenOffice 3.4 have been incorporated
-+ return buf.toString();
-+ }
-+
- private String describe(Session session, int blanks) {
-
- int lIType;
-@@ -1523,6 +1535,12 @@
- return columnName;
- }
-
-+ if (isAggregate(exprType)) {
-+ try {
-+ return getDDL();
-+ } catch (Exception e) {}
-+ }
-+
- return "";
- }
-
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcCallableStatement.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcCallableStatement.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcCallableStatement.java 2008-03-20 02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcCallableStatement.java 2013-07-05 23:45:50.000000000 +0200
-@@ -3376,7 +3376,26 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
--*/
-
-+ public T getObject(int parameterIndex,
-+ Class type) throws SQLException {
-+ return (T) this.getObject(parameterIndex);
-+ }
-+
-+ public T getObject(String parameterName,
-+ Class type) throws SQLException {
-+ return getObject(this.findParameterIndex(parameterName), type);
-+ }
-+
-+ public void closeOnCompletion() throws SQLException {
-+ throw new UnsupportedOperationException("Not supported yet.");
-+ }
-+
-+ public boolean isCloseOnCompletion() throws SQLException {
-+ throw new UnsupportedOperationException("Not supported yet.");
-+ }
-+
-+*/
- //#endif JAVA6
-+
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcConnection.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcConnection.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcConnection.java 2008-03-20 02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcConnection.java 2013-07-05 23:46:02.000000000 +0200
-@@ -2794,6 +2794,36 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public int getNetworkTimeout() throws SQLException {
-+ return 0;
-+ }
-+
-+ public void setNetworkTimeout(java.util.concurrent.Executor executor,
-+ int milliseconds) throws SQLException {
-+
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
-+
-+ public void setSchema(String schema) throws SQLException {
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
-+
-+ public String getSchema() throws SQLException {
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
-+ public void abort(
-+ java.util.concurrent.Executor executor) throws SQLException {
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
- */
-
- //#endif JAVA6
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java 2008-03-20 02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java 2013-07-05 23:46:18.000000000 +0200
-@@ -5694,7 +5694,17 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
--*/
-
-+ public ResultSet getPseudoColumns(
-+ String catalog, String schemaPattern, String tableNamePattern,
-+ String columnNamePattern) throws SQLException {
-+ throw Util.notSupported();
-+ }
-+
-+ public boolean generatedKeyAlwaysReturned() throws SQLException {
-+ return true;
-+ }
-+
-+*/
- //#endif JAVA6
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcDataSource.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcDataSource.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcDataSource.java 2008-05-28 22:23:02.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcDataSource.java 2013-07-05 23:46:39.000000000 +0200
-@@ -322,6 +322,11 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public java.util.logging.Logger getParentLogger()
-+ throws java.sql.SQLFeatureNotSupportedException {
-+ throw (java.sql.SQLFeatureNotSupportedException) Util.notSupported();
-+ }
- */
-
- //#endif JAVA6
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcPreparedStatement.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcPreparedStatement.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcPreparedStatement.java 2008-03-20 02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcPreparedStatement.java 2013-07-05 23:46:54.000000000 +0200
-@@ -2403,6 +2403,15 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public void closeOnCompletion() throws SQLException {
-+ checkClosed();
-+ }
-+
-+ public boolean isCloseOnCompletion() throws SQLException {
-+ checkClosed();
-+ return false;
-+ }
- */
-
- //#endif JAVA6
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcResultSet.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcResultSet.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcResultSet.java 2008-03-20 02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcResultSet.java 2013-07-05 23:47:15.000000000 +0200
-@@ -5325,7 +5325,16 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
--*/
-
-+ public T getObject(int columnIndex, Class type) throws SQLException {
-+ return (T) getObject(columnIndex);
-+ }
-+
-+ public T getObject(String columnLabel,
-+ Class type) throws SQLException {
-+ return getObject(findColumn(columnLabel), type);
-+ }
-+
-+*/
- //#endif JAVA6
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcStatement.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcStatement.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcStatement.java 2008-03-20 02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcStatement.java 2013-07-05 23:47:29.000000000 +0200
-@@ -1608,6 +1608,16 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public void closeOnCompletion() throws SQLException {
-+ checkClosed();
-+ }
-+
-+ public boolean isCloseOnCompletion() throws SQLException {
-+ checkClosed();
-+ return false;
-+ }
-+
- */
- //#endif JAVA6
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbcDriver.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbcDriver.java
---- misc/hsqldb/src/org/hsqldb/jdbcDriver.java 2006-04-11 17:03:24.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/jdbcDriver.java 2013-07-05 23:48:06.000000000 +0200
-@@ -321,4 +321,16 @@
- DriverManager.registerDriver(new jdbcDriver());
- } catch (Exception e) {}
- }
-+
-+//#ifdef JAVA6
-+/*
-+ public java.util.logging
-+ .Logger getParentLogger() throws java.sql
-+ .SQLFeatureNotSupportedException {
-+ throw new UnsupportedOperationException("Not supported yet.");
-+ }
-+*/
-+
-+//#endif
-+
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/lib/StringComparator.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/lib/StringComparator.java
---- misc/hsqldb/src/org/hsqldb/lib/StringComparator.java 2013-07-06 00:32:59.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/lib/StringComparator.java 2013-07-06 00:09:04.000000000 +0200
-@@ -0,0 +1,53 @@
-+/* Copyright (c) 2001-2008, The HSQL Development Group
-+ * All rights reserved.
-+ *
-+ * Redistribution and use in source and binary forms, with or without
-+ * modification, are permitted provided that the following conditions are met:
-+ *
-+ * Redistributions of source code must retain the above copyright notice, this
-+ * list of conditions and the following disclaimer.
-+ *
-+ * Redistributions in binary form must reproduce the above copyright notice,
-+ * this list of conditions and the following disclaimer in the documentation
-+ * and/or other materials provided with the distribution.
-+ *
-+ * Neither the name of the HSQL Development Group nor the names of its
-+ * contributors may be used to endorse or promote products derived from this
-+ * software without specific prior written permission.
-+ *
-+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-+ * ARE DISCLAIMED. IN NO EVENT SHALL HSQL DEVELOPMENT GROUP, HSQLDB.ORG,
-+ * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
-+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
-+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-+ */
-+
-+
-+package org.hsqldb.lib;
-+
-+public class StringComparator implements ObjectComparator {
-+
-+ public int compare(Object a, Object b) {
-+
-+ // handle nulls
-+ if (a == b) {
-+ return 0;
-+ }
-+
-+ if (a == null) {
-+ return -1;
-+ }
-+
-+ if (b == null) {
-+ return 1;
-+ }
-+
-+ return ((String) a).compareTo((String) b);
-+ }
-+}
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Library.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Library.java
---- misc/hsqldb/src/org/hsqldb/Library.java 2006-07-17 00:29:33.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/Library.java 2013-07-05 23:51:13.000000000 +0200
-@@ -1957,7 +1957,7 @@
- functionMap.put("bitand", bitand);
- functionMap.put("bitlength", bitLength);
- functionMap.put("bitor", bitor);
-- functionMap.put("bitxor", bitor);
-+ functionMap.put("bitxor", bitxor);
- functionMap.put("character", character);
- functionMap.put("concat", concat);
- functionMap.put("cot", cot);
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/persist/HsqlDatabaseProperties.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/persist/HsqlDatabaseProperties.java
---- misc/hsqldb/src/org/hsqldb/persist/HsqlDatabaseProperties.java 2008-03-17 17:05:41.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/persist/HsqlDatabaseProperties.java 2013-07-05 23:52:14.000000000 +0200
-@@ -429,6 +429,7 @@
- setProperty(hsqldb_log_size, 10);
- setProperty(sql_enforce_strict_size, true);
- setProperty(hsqldb_nio_data_file, false);
-+ setProperty(hsqldb_lock_file, true);
- }
-
- // OOo end
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Select.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Select.java
---- misc/hsqldb/src/org/hsqldb/Select.java 2007-07-17 18:14:09.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/Select.java 2013-07-05 23:57:48.000000000 +0200
-@@ -33,7 +33,7 @@
- *
- * For work added by the HSQL Development Group:
- *
-- * Copyright (c) 2001-2008, The HSQL Development Group
-+ * Copyright (c) 2001-2005, The HSQL Development Group
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
-@@ -1255,6 +1255,7 @@
- for (int i = 0; i < iResultLen; i++) {
- e = exprColumns[i];
- rmd.colTypes[i] = e.getDataType();
-+ rmd.classNames[i] = e.getValueClassName();
- rmd.colSizes[i] = e.getColumnSize();
- rmd.colScales[i] = e.getColumnScale();
- rmd.colLabels[i] = e.getAlias();
-@@ -1263,6 +1264,7 @@
- rmd.colNames[i] = e.getColumnName();
-
- if (rmd.isTableColumn(i)) {
-+ rmd.schemaNames[i] = e.getTableSchemaName();
- rmd.colNullable[i] = e.nullability;
- rmd.isIdentity[i] = e.isIdentity;
- rmd.isWritable[i] = e.isWritable;
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Table.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Table.java
---- misc/hsqldb/src/org/hsqldb/Table.java 2007-10-19 23:59:07.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/Table.java 2013-07-05 23:58:46.000000000 +0200
-@@ -149,10 +149,10 @@
- Constraint[] constraintList; // constrainst for the table
- HsqlArrayList[] triggerLists; // array of trigger lists
- private int[] colTypes; // fredt - types of columns
-- private int[] colSizes; // fredt - copy of SIZE values for columns
-+ int[] colSizes; // fredt - copy of SIZE values for columns
- private int[] colScales; // fredt - copy of SCALE values for columns
- private boolean[] colNullable; // fredt - modified copy of isNullable() values
-- private Expression[] colDefaults; // fredt - expressions of DEFAULT values
-+ Expression[] colDefaults; // fredt - expressions of DEFAULT values
- private int[] defaultColumnMap; // fred - holding 0,1,2,3,...
- private boolean hasDefaultValues; //fredt - shortcut for above
- boolean sqlEnforceSize; // inherited from the database -
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/TableWorks.java ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/TableWorks.java
---- misc/hsqldb/src/org/hsqldb/TableWorks.java 2007-01-14 06:48:16.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/TableWorks.java 2013-07-05 23:59:03.000000000 +0200
-@@ -670,7 +670,10 @@
- // default expressions can change
- oldCol.setType(newCol);
- oldCol.setDefaultExpression(newCol.getDefaultExpression());
-- table.setColumnTypeVars(colIndex);
-+
-+ table.colSizes[colIndex] = oldCol.getSize();
-+ table.colDefaults[colIndex] = oldCol.getDefaultExpression();
-+
- table.resetDefaultsFlag();
-
- return;
diff --git a/main/hsqldb/patches/runfinalizers.patch b/main/hsqldb/patches/runfinalizers.patch
deleted file mode 100644
index dfeafdfee22..00000000000
--- a/main/hsqldb/patches/runfinalizers.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- misc/build/hsqldb/src/org/hsqldb/lib/java/JavaSystem.java
-+++ misc/build/hsqldb/src/org/hsqldb/lib/java/JavaSystem.java
-@@ -160,7 +160,7 @@
- public static void runFinalizers() {
-
- //#ifdef JAVA2FULL
-- System.runFinalizersOnExit(true);
-+ // System.runFinalizersOnExit(boolean) was removed in Java 11+; dropped for modern JDK compatibility
-
- //#endif
- }
---- misc/build/hsqldb/src/org/hsqldb/lib/HsqlArrayList.java
-+++ misc/build/hsqldb/src/org/hsqldb/lib/HsqlArrayList.java
-@@ -57,7 +57,7 @@
- Reporter() {
-
- try {
-- System.runFinalizersOnExit(true);
-+ // System.runFinalizersOnExit(boolean) was removed in Java 11+; dropped for modern JDK compatibility
- } catch (SecurityException e) {}
- }
-
diff --git a/main/hsqldb/patches/script.patch b/main/hsqldb/patches/script.patch
deleted file mode 100644
index dc722d8198b..00000000000
--- a/main/hsqldb/patches/script.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff -ru misc/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java misc/build/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java
---- misc/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java 2008-05-27 14:26:44.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java 2023-02-19 15:28:44.167555700 +0100
-@@ -402,6 +402,9 @@
- if (tokenizer.getType() != Types.VARCHAR) {
- throw Trace.error(Trace.INVALID_IDENTIFIER);
- }
-+ if (session.isProcessingScript() || session.isProcessingLog()) {
-+ return new Result(ResultConstants.UPDATECOUNT);
-+ }
-
- dsw = new ScriptWriterText(database, token, true, true, true);
-
diff --git a/main/hsqldb/patches/text_tables.patch b/main/hsqldb/patches/text_tables.patch
deleted file mode 100644
index 896c8dc3ce2..00000000000
--- a/main/hsqldb/patches/text_tables.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff -ru misc/hsqldb/src/org/hsqldb/persist/Log.java misc/build/hsqldb/src/org/hsqldb/persist/Log.java
---- misc/hsqldb/src/org/hsqldb/persist/Log.java 2008-03-14 16:47:42.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/persist/Log.java 2026-09-08 22:40:39.681242533 +0200
-@@ -763,7 +763,7 @@
-
- closeTextCache(table);
-
-- if (!properties.isPropertyTrue(
-+ if (database.isStoredFileAccess() || !properties.isPropertyTrue(
- HsqlDatabaseProperties.textdb_allow_full_path)) {
- if (source.indexOf("..") != -1) {
- throw (Trace.error(Trace.ACCESS_IS_DENIED, source));
-
diff --git a/main/hsqldb/prj/d.lst b/main/hsqldb/prj/d.lst
index 8801f4fecfc..38758af25b6 100644
--- a/main/hsqldb/prj/d.lst
+++ b/main/hsqldb/prj/d.lst
@@ -1 +1 @@
-..\%__SRC%\misc\build\hsqldb\lib\hsqldb.jar %_DEST%\bin%_EXT%\hsqldb.jar
+..\%__SRC%\misc\build\hsqldb-2.5.0\hsqldb\lib\hsqldb.jar %_DEST%\bin%_EXT%\hsqldb.jar
diff --git a/main/hsqldb/version.mk b/main/hsqldb/version.mk
index 2ca6ca2df52..9413eaef6f4 100644
--- a/main/hsqldb/version.mk
+++ b/main/hsqldb/version.mk
@@ -20,7 +20,7 @@
# *************************************************************
# when you want to change the HSQLDB version, you must update the d.lst
# in the HSQLDB_thon project accordingly !!!
-HSQLDB_MAJOR=1
-HSQLDB_MINOR=8
+HSQLDB_MAJOR=2
+HSQLDB_MINOR=5
HSQLDB_MICRO=0
-HSQLDB_VERSION=$(HSQLDB_MAJOR)_$(HSQLDB_MINOR)_$(HSQLDB_MICRO)
+HSQLDB_VERSION=$(HSQLDB_MAJOR).$(HSQLDB_MINOR).$(HSQLDB_MICRO)
From d53e7144b6e81452cafac62d3bfb58354dd2dbc1 Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sat, 7 Nov 2026 04:33:51 -0500
Subject: [PATCH 02/11] hsqldb: add RESTRICT to REVOKE, which HSQLDB 2.x
requires
---
main/connectivity/source/drivers/hsqldb/HUser.cxx | 1 +
1 file changed, 1 insertion(+)
diff --git a/main/connectivity/source/drivers/hsqldb/HUser.cxx b/main/connectivity/source/drivers/hsqldb/HUser.cxx
index 59de21b53cc..8fa80ee9e5a 100644
--- a/main/connectivity/source/drivers/hsqldb/HUser.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HUser.cxx
@@ -271,6 +271,7 @@ void SAL_CALL OHSQLUser::revokePrivileges( const ::rtl::OUString& objName, sal_I
sGrant += ::dbtools::quoteTableName(xMeta,objName,::dbtools::eInDataManipulation);
sGrant += ::rtl::OUString::createFromAscii(" FROM ");
sGrant += m_Name;
+ sGrant += ::rtl::OUString::createFromAscii(" RESTRICT");
Reference xStmt = m_xConnection->createStatement();
if(xStmt.is())
From 9b39f55b2054fe49e1f631d52104110025e4b46a Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sat, 7 Nov 2026 04:33:52 -0500
Subject: [PATCH 03/11] LICENSE: add the HSQL Development Group notice for the
bundled HSQLDB 2.5.0
---
main/LICENSE | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)
diff --git a/main/LICENSE b/main/LICENSE
index 597c1d4a11c..ea21f813211 100644
--- a/main/LICENSE
+++ b/main/LICENSE
@@ -1056,6 +1056,39 @@ ____
For integration of HSQLDB - built in main/hsqldb/
+For work developed by the HSQL Development Group:
+
+Copyright (c) 2001-2019, The HSQL Development Group
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+Redistributions of source code must retain the above copyright notice, this
+list of conditions and the following disclaimer.
+
+Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+
+Neither the name of the HSQL Development Group nor the names of its
+contributors may be used to endorse or promote products derived from this
+software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL HSQL DEVELOPMENT GROUP, HSQLDB.ORG,
+OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+For work originally developed by the Hypersonic SQL Group:
+
Copyright (c) 1995-2000 by the Hypersonic SQL Group.
All rights reserved.
From de5508cd86423d926c1ce1812331a2c78c2915ee Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sat, 7 Nov 2026 04:33:52 -0500
Subject: [PATCH 04/11] configure: reject --with-system-hsqldb, a system hsqldb
lacks the storage hooks
---
main/configure.ac | 39 +++------------------------------------
1 file changed, 3 insertions(+), 36 deletions(-)
diff --git a/main/configure.ac b/main/configure.ac
index f63397d0f18..f518686b11b 100644
--- a/main/configure.ac
+++ b/main/configure.ac
@@ -501,7 +501,7 @@ AC_ARG_WITH(system-mysql-cppconn,
[ --with-system-mysql-cppconn Use MySQL C++ Connector libraries already on system
],,)
AC_ARG_WITH(system-hsqldb,
-[ --with-system-hsqldb Use hsqldb already on system
+[ --with-system-hsqldb Not supported: the bundled hsqldb carries the storage access patch
],,)
AC_ARG_WITH(hsqldb-jar,
[ --with-hsqldb-jar=JARFILE Specify path to jarfile manually ],
@@ -5001,42 +5001,9 @@ dnl ===================================================================
dnl Check for system hsqldb
dnl ===================================================================
AC_MSG_CHECKING([which hsqldb to use])
-if test -n "$with_system_hsqldb" -o -n "$with_system_libs" && \
- test "$with_system_hsqldb" != "no" && test "$with_system_jars" != "no"; then
+if test -n "$with_system_hsqldb" && test "$with_system_hsqldb" != "no"; then
AC_MSG_RESULT([external])
- SYSTEM_HSQLDB=YES
- if test -z $HSQLDB_JAR; then
- HSQLDB_JAR=/usr/share/java/hsqldb.jar
- fi
- AC_CHECK_FILE($HSQLDB_JAR, [],
- [AC_MSG_ERROR(hsqldb.jar not found.)], [])
-AC_MSG_CHECKING([whether hsqldb is newer than 2.7])
- export HSQLDB_JAR
- if $PERL -e 'use Archive::Zip;
- my $file = "$ENV{'HSQLDB_JAR'}";
- my $zip = Archive::Zip->new( $file );
- my $mf = $zip->contents ( "META-INF/MANIFEST.MF" );
- if ( $mf =~ m/Specification-Version: 2\.\d+\.\d+/ ) {
- push @l, split(/\n/, $mf);
- foreach my $line (@l) {
- if ($line =~ m/Specification-Version:/) {
- ($t, $version) = split (/:/,$line);
- $version =~ s/^\s//;
- ($a, $b, $c) = split (/\./,$version);
- if ($a == 2 && ($b > 7 || ($b == 7 && $c > 0))) {
- exit 0;
- } else {
- exit 1;
- }
- }
- }
- } else {
- exit 1;
- }'; then
- AC_MSG_RESULT([yes])
- else
- AC_MSG_ERROR([no, you need hsqldb > 2.7])
- fi
+ AC_MSG_ERROR([a system hsqldb cannot be used: the bundled hsqldb carries main/hsqldb/patches/aoo_integration.patch])
else
AC_MSG_RESULT([internal])
SYSTEM_HSQLDB=NO
From 1333d67c799b27c54be527850670a064eb5a119e Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sat, 7 Nov 2026 04:33:52 -0500
Subject: [PATCH 05/11] hsqldb: send the data, LOB and backup files through the
storage
The patch now throws when the storage class cannot be loaded instead of
falling back to the file system.
---
main/hsqldb/patches/aoo_integration.patch | 376 +++++++++++++++-------
1 file changed, 256 insertions(+), 120 deletions(-)
diff --git a/main/hsqldb/patches/aoo_integration.patch b/main/hsqldb/patches/aoo_integration.patch
index 02ff348dd2f..cbd2d43bc4a 100644
--- a/main/hsqldb/patches/aoo_integration.patch
+++ b/main/hsqldb/patches/aoo_integration.patch
@@ -1,160 +1,296 @@
---- misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/Logger.java 2019-05-31 10:26:20.000000000 -0500
-+++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/Logger.java 2026-11-06 10:22:37.173757415 -0500
-@@ -62,6 +62,7 @@
- import org.hsqldb.lib.FileAccess;
- import org.hsqldb.lib.FileUtil;
- import org.hsqldb.lib.FrameworkLogger;
+--- misc/hsqldb/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/Logger.java
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/Logger.java
+@@ -34,6 +34,7 @@
+ import java.io.File;
+ import java.io.FileInputStream;
+ import java.io.IOException;
+import java.lang.reflect.Constructor;
- import org.hsqldb.lib.HsqlArrayList;
- import org.hsqldb.lib.InputStreamInterface;
- import org.hsqldb.lib.InputStreamWrapper;
-@@ -183,6 +184,26 @@
- this.database = database;
- }
+ import java.text.SimpleDateFormat;
+ import java.util.Locale;
+ import java.util.concurrent.atomic.AtomicInteger;
+@@ -137,6 +138,7 @@
+ private Crypto crypto;
+ boolean cryptLobs;
+ public FileAccess fileAccess;
++ private boolean isStoredFileAccess;
+ String tempDirectoryPath;
-+ private static FileAccess getFileAccessCustom(Database database) {
-+ String fileAccessClassName = database.urlProperties.getProperty("fileaccess_class_name");
-+ if (fileAccessClassName != null && !fileAccessClassName.isEmpty()) {
-+ try {
-+ Class> fileAccessClass = Class.forName(fileAccessClassName);
-+ String storageKey = database.urlProperties.getProperty("storage_key");
-+ if (storageKey != null) {
-+ Constructor> ctor = fileAccessClass.getConstructor(Object.class);
-+ return (FileAccess) ctor.newInstance(storageKey);
-+ } else {
-+ Constructor> ctor = fileAccessClass.getConstructor();
-+ return (FileAccess) ctor.newInstance();
-+ }
-+ } catch (Exception e) {
-+ return FileUtil.getFileAccess(database.isFilesInJar());
-+ }
-+ }
-+ return FileUtil.getFileAccess(database.isFilesInJar());
-+ }
-+
- /**
- * Opens the specified Database object's database files and starts up
- * the logging process.
-@@ -198,7 +219,7 @@
+ //
+@@ -198,7 +200,12 @@
boolean hasFileProps = false;
boolean hasScript = false;
- fileAccess = FileUtil.getFileAccess(database.isFilesInJar());
-+ fileAccess = getFileAccessCustom(database);
++ fileAccess = newStoredFileAccess();
++
++ if (fileAccess == null) {
++ fileAccess = FileUtil.getFileAccess(database.isFilesInJar());
++ }
++
propIsFileDatabase = database.getType().isFileBased();
database.databaseProperties = new HsqlDatabaseProperties(database);
propTextAllowFullPath = database.databaseProperties.isPropertyTrue(
---- misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAFile.java 2019-04-27 08:55:26.000000000 -0500
-+++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAFile.java 2026-11-06 10:22:37.174321115 -0500
-@@ -43,6 +43,8 @@
- import org.hsqldb.lib.ArrayUtil;
- import org.hsqldb.lib.HsqlByteArrayInputStream;
- import org.hsqldb.lib.HsqlByteArrayOutputStream;
-+import org.hsqldb.lib.Storage;
-+import java.lang.reflect.Constructor;
+@@ -283,6 +290,12 @@
+ database.databaseProperties.setProperty(
+ HsqlDatabaseProperties.hsqldb_lock_file, false);
+ }
++ }
++
++ // the shadow file used for incremental backup is not reachable through FileAccess
++ if (isStoredFileAccess) {
++ database.databaseProperties.setProperty(
++ HsqlDatabaseProperties.hsqldb_inc_backup, false);
+ }
- /**
- * This class is a wrapper for a random access file such as that used for
-@@ -93,6 +95,20 @@
- String name, boolean readonly,
- int type) throws FileNotFoundException, IOException {
+ setVariables();
+@@ -391,6 +404,10 @@
+ if (database.getType() == DatabaseType.DB_MEM) {
+ tempDirectoryPath = database.getProperties().getStringProperty(
+ HsqlDatabaseProperties.hsqldb_temp_directory);
++ } else if (isStoredFileAccess) {
++
++ // no temporary directory next to the document
++ tempDirectoryPath = null;
+ } else {
+ tempDirectoryPath = database.getPath() + ".tmp";
+ }
+@@ -1102,7 +1119,7 @@
-+ String storageClassName = database.urlProperties.getProperty("storage_class_name");
-+ if (storageClassName != null && !storageClassName.isEmpty()) {
-+ try {
-+ Class> storageClass = Class.forName(storageClassName);
-+ String storageKey = database.urlProperties.getProperty("storage_key");
-+ Constructor> ctor = storageClass.getConstructor(
-+ String.class, Boolean.class, Object.class);
-+ Storage storage = (Storage) ctor.newInstance(
-+ name, Boolean.valueOf(readonly), storageKey);
-+ return new RAStorageWrapper(storage);
-+ } catch (Exception e) {
-+ // fall through to default implementation
-+ }
-+ }
- if (type == DATA_FILE_JAR) {
- return new RAFileInJar(name);
- } else if (type == DATA_FILE_TEXT) {
-@@ -424,6 +440,81 @@
+ public synchronized void setIncrementBackup(boolean val) {
+
+- if (val == propIncrementBackup) {
++ if (val == propIncrementBackup || isStoredFileAccess) {
+ return;
}
- }
+@@ -1313,8 +1330,67 @@
+
+ public FileAccess getFileAccess() {
+ return fileAccess;
++ }
++
+ /**
-+ * Wrapper that adapts org.hsqldb.lib.Storage to
-+ * org.hsqldb.persist.RandomAccessInterface.
-+ * Used for OpenOffice.org storage integration.
++ * True if the database files are kept in a storage supplied by the host
++ * application instead of the file system.
+ */
-+ static class RAStorageWrapper implements RandomAccessInterface {
-+ private final Storage storage;
++ public boolean isStoredFileAccess() {
++ return isStoredFileAccess;
++ }
+
-+ RAStorageWrapper(Storage storage) {
-+ this.storage = storage;
-+ }
++ // oj@openoffice.org - the database files are accessed through a class
++ // named in the connection properties, with a key identifying the storage
++ static final String url_fileaccess_class_name = "fileaccess_class_name";
++ static final String url_storage_class_name = "storage_class_name";
++ static final String url_storage_key = "storage_key";
+
-+ public long length() throws IOException {
-+ return storage.length();
-+ }
++ static Class> loadStorageClass(String name) throws ClassNotFoundException {
+
-+ public void seek(long position) throws IOException {
-+ storage.seek(position);
-+ }
++ ClassLoader loader = Thread.currentThread().getContextClassLoader();
+
-+ public long getFilePointer() throws IOException {
-+ return storage.getFilePointer();
++ if (loader != null) {
++ try {
++ return loader.loadClass(name);
++ } catch (ClassNotFoundException e) {}
+ }
+
-+ public int read() throws IOException {
-+ return storage.read();
-+ }
++ return Class.forName(name);
+ }
+
++ private FileAccess newStoredFileAccess() {
+
-+ public void read(byte[] b, int offset, int length) throws IOException {
-+ storage.read(b, offset, length);
-+ }
++ String className =
++ database.urlProperties.getProperty(url_fileaccess_class_name);
+
-+ public void write(byte[] b, int offset, int length) throws IOException {
-+ storage.write(b, offset, length);
++ if (className == null) {
++ return null;
+ }
+
-+ public int readInt() throws IOException {
-+ return storage.readInt();
-+ }
++ try {
++ Class> fileAccessClass = loadStorageClass(className);
+
-+ public void writeInt(int i) throws IOException {
-+ storage.writeInt(i);
-+ }
++ if (!FileAccess.class.isAssignableFrom(fileAccessClass)) {
++ throw new ClassCastException(className);
++ }
+
-+ public long readLong() throws IOException {
-+ return storage.readLong();
-+ }
++ Constructor> constructor =
++ fileAccessClass.getConstructor(Object.class);
++ FileAccess access = (FileAccess) constructor.newInstance(
++ database.urlProperties.getProperty(url_storage_key));
+
-+ public void writeLong(long i) throws IOException {
-+ storage.writeLong(i);
-+ }
++ isStoredFileAccess = true;
+
-+ public void close() throws IOException {
-+ storage.close();
++ return access;
++ } catch (Throwable t) {
++ throw Error.error(t, ErrorCode.FILE_IO_ERROR,
++ ErrorCode.M_Message_Pair, new Object[] {
++ t.toString(), className
++ });
+ }
++ }
+
-+ public boolean isReadOnly() {
-+ return storage.isReadOnly();
-+ }
+ public boolean isFileDatabase() {
+ return propIsFileDatabase;
+ }
+--- misc/hsqldb/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAStorageWrapper.java
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAStorageWrapper.java
+@@ -32,7 +32,9 @@
+ package org.hsqldb.persist;
+
+ import java.io.IOException;
++import java.lang.reflect.Constructor;
+
++import org.hsqldb.Database;
+ import org.hsqldb.lib.Storage;
+
+ /**
+@@ -52,6 +54,36 @@
+ this.file = virtualFile;
+ }
+
++ /**
++ * Opens a file in the storage supplied by the host application, using the
++ * class and key given in the connection properties.
++ */
++ static RAStorageWrapper newInstance(Database database, String name,
++ boolean readonly) throws IOException {
+
-+ public void synch() {
-+ // Storage interface does not have synch, delegate to no-op
-+ }
++ String className =
++ database.urlProperties.getProperty(Logger.url_storage_class_name);
++
++ try {
++ Class> storageClass = Logger.loadStorageClass(className);
++
++ if (!Storage.class.isAssignableFrom(storageClass)) {
++ throw new ClassCastException(className);
++ }
++
++ Constructor> constructor =
++ storageClass.getConstructor(String.class, Boolean.class,
++ Object.class);
++ Storage storage = (Storage) constructor.newInstance(name,
++ Boolean.valueOf(readonly),
++ database.urlProperties.getProperty(Logger.url_storage_key));
+
-+ public boolean ensureLength(long newLength) {
-+ // Storage interface does not have ensureLength
-+ return true;
++ return new RAStorageWrapper(storage);
++ } catch (Exception e) {
++ throw new IOException("invalid storage class: " + e, e);
+ }
++ }
+
-+ public boolean setLength(long newLength) {
-+ // Storage interface does not have setLength
-+ return false;
+ public long length() throws IOException {
+ return file.length();
+ }
+--- misc/hsqldb/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAFile.java
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/RAFile.java
+@@ -92,6 +92,10 @@
+ static RandomAccessInterface newScaledRAFile(Database database,
+ String name, boolean readonly,
+ int type) throws FileNotFoundException, IOException {
++
++ if (type == DATA_FILE_STORED) {
++ return RAStorageWrapper.newInstance(database, name, readonly);
++ }
+
+ if (type == DATA_FILE_JAR) {
+ return new RAFileInJar(name);
+--- misc/hsqldb/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/DataFileCache.java
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/DataFileCache.java
+@@ -156,7 +156,7 @@
+ cache = new Cache(this);
+
+ try {
+- dataFile = new RAFileSimple(database.logger, dataFileName, "rw");
++ dataFile = newSimpleFile(false);
+ } catch (Throwable t) {
+ throw Error.error(ErrorCode.FILE_IO_ERROR, t);
+ }
+@@ -224,6 +224,8 @@
+
+ if (database.isFilesInJar()) {
+ fileType = RAFile.DATA_FILE_JAR;
++ } else if (database.logger.isStoredFileAccess()) {
++ fileType = RAFile.DATA_FILE_STORED;
+ } else if (isNio) {
+ fileType = RAFile.DATA_FILE_NIO;
+ } else {
+@@ -263,8 +265,7 @@
+ boolean isSaved = false;
+
+ if (preexists) {
+- dataFile = new RAFileSimple(database.logger, dataFileName,
+- "r");
++ dataFile = newSimpleFile(true);
+
+ long length = dataFile.length();
+ boolean wrongVersion = false;
+@@ -389,7 +390,20 @@
+ ErrorCode.M_DataFileCache_open, new Object[] {
+ t.toString(), dataFileName
+ });
+ }
+ }
+
- private void resetPointer() {
++ private RandomAccessInterface newSimpleFile(boolean readonly)
++ throws IOException {
++
++ if (database.logger.isStoredFileAccess()) {
++ return RAStorageWrapper.newInstance(database, dataFileName,
++ readonly);
+ }
++
++ return new RAFileSimple(database.logger, dataFileName,
++ readonly ? "r"
++ : "rw");
+ }
+
+ boolean setDataSpaceManager() {
+@@ -1368,7 +1382,29 @@
+ * @throws HsqlException
+ */
+ void backupDataFile(boolean newFile) {
+- backupFile(database, dataFileName, backupFileName, newFile);
++
++ if (!database.logger.isStoredFileAccess() || dataFile == null) {
++ backupFile(database, dataFileName, backupFileName, newFile);
++
++ return;
++ }
++
++ // the storage keeps one handle per file: reading the data file for
++ // the archive would close the handle held by this cache
++ try {
++ dataFile.close();
++ backupFile(database, dataFileName, backupFileName, newFile);
++ } catch (IOException e) {
++ throw Error.error(ErrorCode.DATA_FILE_ERROR, e);
++ } finally {
++ try {
++ dataFile = RAFile.newScaledRAFile(database, dataFileName,
++ false,
++ RAFile.DATA_FILE_STORED);
++ } catch (IOException e) {
++ throw Error.error(ErrorCode.DATA_FILE_ERROR, e);
++ }
++ }
+ }
+ void backupNewDataFile(boolean newFile) {
+--- misc/hsqldb/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/LobStoreRAFile.java
++++ misc/build/hsqldb-2.5.0/hsqldb/src/org/hsqldb/persist/LobStoreRAFile.java
+@@ -70,8 +70,14 @@
try {
+ boolean readonly = database.isFilesReadOnly();
+
+- file = new RAFileSimple(database.logger, fileName, readonly ? "r"
+- : "rws");
++ if (database.logger.isStoredFileAccess()) {
++ file = RAStorageWrapper.newInstance(database, fileName,
++ readonly);
++ } else {
++ file = new RAFileSimple(database.logger, fileName,
++ readonly ? "r"
++ : "rws");
++ }
+ } catch (Throwable t) {
+ throw Error.error(ErrorCode.DATA_FILE_ERROR, t);
+ }
From c23c53be7c707e466b635b6cc8aa3d3d331446f1 Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sun, 8 Nov 2026 07:37:16 -0500
Subject: [PATCH 06/11] hsqldb: ask before converting a 1.8 database, and don't
open it on a 'No'
dbaccess never passed the document's InteractionHandler to the driver.
With no answer at all it still converts, since headless the default handler
answers nothing.
The prompt holds the data source mutex; a connect from another thread can deadlock.
---
main/connectivity/source/drivers/hsqldb/HDriver.cxx | 12 ++++--------
main/connectivity/source/inc/resource/hsqldb_res.hrc | 2 +-
.../connectivity/source/resource/conn_shared_res.src | 6 +++---
main/dbaccess/source/core/dataaccess/datasource.cxx | 9 +++++++++
4 files changed, 17 insertions(+), 12 deletions(-)
diff --git a/main/connectivity/source/drivers/hsqldb/HDriver.cxx b/main/connectivity/source/drivers/hsqldb/HDriver.cxx
index 7dae08691d5..d51e2e48422 100644
--- a/main/connectivity/source/drivers/hsqldb/HDriver.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HDriver.cxx
@@ -273,7 +273,7 @@ namespace connectivity
aProperties.put( "jdbc.interval_as_varchar", ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
aProperties.put( "get_column_name", ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "false" ) ) );
- bool bAskUser = false,bModified = false;
+ bool bAskUser = false;
::rtl::OUString sMessage;
::rtl::OUString sProperties( RTL_CONSTASCII_USTRINGPARAM( "properties" ) );
try
@@ -298,10 +298,6 @@ namespace connectivity
{
sVersionString = sValue;
}
- else if ( sLine.Equals("modified=yes",0,sizeof("modified=yes")-1) )
- {
- bModified = true;
- }
else
{
if ( ( sVersionString.Len() == 0 )
@@ -352,11 +348,11 @@ namespace connectivity
OInteraction< XInteractionDisapprove >* pDisApprove = new OInteraction< XInteractionDisapprove >;
pRequest->addContinuation(pDisApprove);
xInteraction->handle(xRequest);
- if ( !pDisApprove->wasSelected() )
+ if ( pDisApprove->wasSelected() )
{
- bAskUser = false;
+ StorageContainer::revokeStorage(sKey,NULL);
+ ::dbtools::throwGenericSQLException(aResources.getResourceString(STR_CONVERSION_DECLINED) ,*this);
}
- aProperties.put( "sql.enforce_size", ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "false" ) ) );
}
// readonly?
diff --git a/main/connectivity/source/inc/resource/hsqldb_res.hrc b/main/connectivity/source/inc/resource/hsqldb_res.hrc
index e3cdec1adb8..d5964ced9ad 100644
--- a/main/connectivity/source/inc/resource/hsqldb_res.hrc
+++ b/main/connectivity/source/inc/resource/hsqldb_res.hrc
@@ -39,6 +39,6 @@
#define STR_NO_DOCUMENTUI ( STR_HSQLDB_BASE + 5 )
#define STR_ERROR_NEW_VERSION ( STR_HSQLDB_BASE + 6 )
#define STR_CONVERT_TO_NEW_VERSION ( STR_HSQLDB_BASE + 7 )
-#define STR_SHUTDOWN_REQUIRED ( STR_HSQLDB_BASE + 8 )
+#define STR_CONVERSION_DECLINED ( STR_HSQLDB_BASE + 8 )
#endif // CONNECTIVITY_RESOURCE_HSQLDB_HRC
diff --git a/main/connectivity/source/resource/conn_shared_res.src b/main/connectivity/source/resource/conn_shared_res.src
index 8fce2a26cbf..96b98520285 100644
--- a/main/connectivity/source/resource/conn_shared_res.src
+++ b/main/connectivity/source/resource/conn_shared_res.src
@@ -635,11 +635,11 @@ String STR_ERROR_NEW_VERSION
};
String STR_CONVERT_TO_NEW_VERSION
{
- Text = "The database file is stored in an old version. Do you want to convert into the new version?" ;
+ Text [ en-US ] = "The database file is stored in an old version. Do you want to convert into the new version?" ;
};
-String STR_SHUTDOWN_REQUIRED
+String STR_CONVERSION_DECLINED
{
- Text = "The database file was not stored correctly by a previous version of %PRODUCTNAME.\nPlease open the file with Apache OpenOffice 4.1.x, then click the Tables icon and save." ;
+ Text [ en-US ] = "The database was not opened because it was not converted to the new version." ;
};
// ********************************************************************** EOF
diff --git a/main/dbaccess/source/core/dataaccess/datasource.cxx b/main/dbaccess/source/core/dataaccess/datasource.cxx
index 67a21fbfa7f..5c16f7aed48 100644
--- a/main/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/main/dbaccess/source/core/dataaccess/datasource.cxx
@@ -764,6 +764,15 @@ Reference< XConnection > ODatabaseSource::buildLowLevelConnection(const ::rtl::O
aDriverInfo[nCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Storage"));
Reference< css::document::XDocumentSubStorageSupplier> xDocSup( m_pImpl->getDocumentSubStorageSupplier() );
aDriverInfo[nCount++].Value <<= xDocSup->getDocumentSubStorage(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("database")),ElementModes::READWRITE);
+
+ // lets the embedded driver ask before it converts a database from an older engine
+ Reference< XInteractionHandler > xHandler( m_pImpl->getMediaDescriptor().getOrDefault( "InteractionHandler", Reference< XInteractionHandler >() ) );
+ if ( xHandler.is() )
+ {
+ aDriverInfo.realloc( nCount + 1 );
+ aDriverInfo[nCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("InteractionHandler"));
+ aDriverInfo[nCount++].Value <<= xHandler;
+ }
}
if (nAdditionalArgs)
xReturn = xManager->getConnectionWithInfo(m_pImpl->m_sConnectURL, ::comphelper::concatSequences(aUserPwd,aDriverInfo));
From df745297953a29527df4ba959d9061528d02f4cf Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sun, 8 Nov 2026 07:37:42 -0500
Subject: [PATCH 07/11] hsqldb: stop the jar task writing four classes into
hsqldb.jar twice
---
main/hsqldb/makefile.mk | 2 +-
main/hsqldb/patches/jar_duplicates.patch | 11 +++++++++++
2 files changed, 12 insertions(+), 1 deletion(-)
create mode 100644 main/hsqldb/patches/jar_duplicates.patch
diff --git a/main/hsqldb/makefile.mk b/main/hsqldb/makefile.mk
index 8843054009e..baed998fb76 100644
--- a/main/hsqldb/makefile.mk
+++ b/main/hsqldb/makefile.mk
@@ -48,7 +48,7 @@ TARFILE_ROOTDIR=hsqldb-$(HSQLDB_VERSION)$/hsqldb
CONVERTFILES=build$/build.xml \
src$/org$/hsqldb$/persist$/HsqlDatabaseProperties.java
-PATCH_FILES=patches$/aoo_integration.patch
+PATCH_FILES=patches$/aoo_integration.patch patches$/jar_duplicates.patch
JAVAC_SRCTGT=-Dant.build.javac.source=1.8 -Dant.build.javac.target=1.8
diff --git a/main/hsqldb/patches/jar_duplicates.patch b/main/hsqldb/patches/jar_duplicates.patch
new file mode 100644
index 00000000000..127fba430e8
--- /dev/null
+++ b/main/hsqldb/patches/jar_duplicates.patch
@@ -0,0 +1,11 @@
+--- misc/hsqldb/hsqldb-2.5.0/hsqldb/build/build.xml
++++ misc/build/hsqldb-2.5.0/hsqldb/build/build.xml
+@@ -595,7 +595,7 @@
+
+
+-
++
+
+
+
From 78a00c0bf03bedf246521c59eb3a7c7185d0cd33 Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sun, 8 Nov 2026 07:38:11 -0500
Subject: [PATCH 08/11] connectivity: check for NULL before comparing values of
different types
With the type check first, a NULL DOUBLE was equal to an INTEGER 0.
---
main/connectivity/source/commontools/FValue.cxx | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/main/connectivity/source/commontools/FValue.cxx b/main/connectivity/source/commontools/FValue.cxx
index a449c8c565a..e3f09e3ae0b 100644
--- a/main/connectivity/source/commontools/FValue.cxx
+++ b/main/connectivity/source/commontools/FValue.cxx
@@ -783,6 +783,12 @@ sal_Bool operator==(const DateTime& _rLH,const DateTime& _rRH)
bool ORowSetValue::operator==(const ORowSetValue& _rRH) const
{
+ if ( m_bNull != _rRH.isNull() )
+ return false;
+
+ if(m_bNull && _rRH.isNull())
+ return true;
+
if ( m_eTypeKind != _rRH.m_eTypeKind )
{
switch(m_eTypeKind)
@@ -805,10 +811,6 @@ bool ORowSetValue::operator==(const ORowSetValue& _rRH) const
}
return false;
}
- if ( m_bNull != _rRH.isNull() )
- return false;
- if(m_bNull && _rRH.isNull())
- return true;
bool bRet = false;
OSL_ENSURE(!m_bNull,"SHould not be null!");
From aac6cdf4a7e9a90fd43e6d3ff467c9a77a9c21ac Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Sun, 8 Nov 2026 07:38:34 -0500
Subject: [PATCH 09/11] hsqldb: drop whitespace changes in HStorageMap.cxx,
restore a makefile comment
---
main/connectivity/source/drivers/hsqldb/HStorageMap.cxx | 4 ++--
main/hsqldb/makefile.mk | 2 ++
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx b/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
index 56607a1ac86..1300df1c79d 100644
--- a/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
@@ -58,8 +58,8 @@ namespace connectivity
{
try
{
- m_xStream.clear();
- m_xSeek.clear();
+ m_xStream.clear();
+ m_xSeek.clear();
if ( m_xInputStream.is() )
{
m_xInputStream->closeInput();
diff --git a/main/hsqldb/makefile.mk b/main/hsqldb/makefile.mk
index baed998fb76..351708e0e95 100644
--- a/main/hsqldb/makefile.mk
+++ b/main/hsqldb/makefile.mk
@@ -50,6 +50,8 @@ CONVERTFILES=build$/build.xml \
PATCH_FILES=patches$/aoo_integration.patch patches$/jar_duplicates.patch
+# hsqldb's build.xml javac tasks specify no source/target; pin them so bytecode
+# stays Java 8 compatible regardless of the (possibly much newer) build JDK.
JAVAC_SRCTGT=-Dant.build.javac.source=1.8 -Dant.build.javac.target=1.8
.IF "$(JAVACISGCJ)"=="yes"
From 994d66e60594690c6282ab00a97cf64a7d2fbcff Mon Sep 17 00:00:00 2001
From: Jim Jagielski
Date: Mon, 9 Nov 2026 03:04:28 -0500
Subject: [PATCH 10/11] Sync with trunk (#519)
* Replace std::hash_map/hash_set with std::unordered_map/unordered_set on trunk (C++11)
GCC 15 removed std::hash_map/std::hash_set (GNU extensions) from libstdc++.
Replace all 628 occurrences across 477 files with std::unordered_map/
std::unordered_set, updating #include / to
Affects: vcl, crashrep, extensions, dbaccess, scripting, sw, io, rdbmaker,
codemaker, unodevtools, and many other modules.
* Migrate remaining std::hash_map/std::hash_set to std::unordered_map/std::unordered_set
Replace TR1/backport hash containers with C++11 standard equivalents
in source files not yet covered by trunk's migration.
* Replace std::hash_multimap with std::unordered_multimap in propcontroller.hxx
std::hash_multimap is a GNU extension removed from GCC 13's libstdc++,
causing a build failure in the pcr module (propcontroller.obj).
std::unordered_multimap is the C++11 standard equivalent already used
elsewhere in this file and supports all operations performed on
m_aDependencyHandlers.
* Replace std::hash_multimap with std::unordered_multimap in oleobjw.hxx
std::hash_multimap is a GNU extension removed from GCC 13's libstdc++.
The functors hashOUString_Impl/equalOUString_Impl are already used with
std::unordered_map on line 74 of the same file, and all operations on
m_mapComFunc (find, end, insert) are supported by std::unordered_multimap.
---------
Co-authored-by: Pedro F. Giffuni
---
.../extended/textwindowaccessibility.hxx | 4 +-
.../extended/textwindowaccessibility.cxx | 2 +-
.../animcore/targetpropertiescreator.cxx | 6 +-
main/avmedia/source/macavf/macavf_player.cxx | 4 +-
main/basctl/source/inc/bastypes.hxx | 4 +-
main/basic/source/classes/sb.cxx | 6 +-
main/basic/source/classes/sbunoobj.cxx | 6 +-
main/basic/source/comp/sbcomp.cxx | 8 +-
main/basic/source/inc/namecont.hxx | 4 +-
main/basic/source/inc/scriptcont.hxx | 2 +-
main/basic/source/runtime/step0.cxx | 4 +-
.../bridges/cpp_uno/shared/vtablefactory.hxx | 4 +-
.../cpp_uno/gcc3_freebsd_aarch64/cpp2uno.cxx | 2 +-
.../cpp_uno/gcc3_freebsd_aarch64/except.cxx | 8 +-
.../cpp_uno/gcc3_freebsd_arm/cpp2uno.cxx | 2 +-
.../cpp_uno/gcc3_freebsd_arm/except.cxx | 4 +-
.../cpp_uno/gcc3_freebsd_intel/except.cxx | 4 +-
.../cpp_uno/gcc3_freebsd_powerpc/except.cxx | 4 +-
.../cpp_uno/gcc3_freebsd_powerpc64/except.cxx | 4 +-
.../cpp_uno/gcc3_freebsd_x86-64/except.cxx | 4 +-
.../cpp_uno/gcc3_linux_alpha/except.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_arm/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_hppa/cpp2uno.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_hppa/except.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_ia64/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_intel/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_m68k/cpp2uno.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_m68k/except.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_mips/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_powerpc/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_powerpc64/except.cxx | 2 +-
.../source/cpp_uno/gcc3_linux_s390/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_s390x/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_sparc/except.cxx | 2 +-
.../cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx | 2 +-
.../cpp_uno/gcc3_linux_x86-64/except.cxx | 2 +-
.../cpp_uno/gcc3_netbsd_intel/cpp2uno.cxx | 4 +-
.../cpp_uno/gcc3_netbsd_intel/except.cxx | 2 +-
.../source/cpp_uno/gcc3_os2_intel/except.cxx | 2 +-
.../cpp_uno/gcc3_solaris_intel/except.cxx | 2 +-
.../cpp_uno/gcc3_solaris_sparc/except.cxx | 2 +-
.../source/cpp_uno/mingw_intel/except.cxx | 2 +-
.../cpp_uno/msvc_win32_intel/except.cxx | 2 +-
.../cpp_uno/msvc_win64_x86-64/except.cxx | 2 +-
.../cpp_uno/s5abi_macosx_aarch64/cpp2uno.cxx | 2 +-
.../cpp_uno/s5abi_macosx_aarch64/except.cxx | 2 +-
.../cpp_uno/s5abi_macosx_x86-64/cpp2uno.cxx | 2 +-
.../cpp_uno/s5abi_macosx_x86-64/except.cxx | 2 +-
.../source/cpp_uno/shared/vtablefactory.cxx | 4 +-
main/chart2/source/inc/DataSeriesHelper.hxx | 2 +-
main/codemaker/inc/codemaker/dependencies.hxx | 4 +-
.../inc/codemaker/generatedtypeset.hxx | 4 +-
main/codemaker/inc/codemaker/options.hxx | 4 +-
main/codemaker/inc/codemaker/typemanager.hxx | 4 +-
.../source/bonobowrappermaker/corbatype.cxx | 2 +-
.../source/bonobowrappermaker/corbatype.hxx | 4 +-
.../comphelper/ChainablePropertySetInfo.hxx | 2 +-
.../inc/comphelper/PropertyInfoHash.hxx | 6 +-
.../inc/comphelper/mediadescriptor.hxx | 2 +-
.../inc/comphelper/numberedcollection.hxx | 4 +-
.../inc/comphelper/sequenceashashmap.hxx | 4 +-
.../container/embeddedobjectcontainer.cxx | 4 +-
.../source/misc/namedvaluecollection.cxx | 4 +-
.../source/inc/TSkipDeletedSet.hxx | 2 +-
main/cppu/source/LogBridge/LogBridge.cxx | 2 +-
main/cppu/source/threadpool/threadpool.cxx | 4 +-
main/cppu/source/threadpool/threadpool.hxx | 4 +-
main/cppu/source/typelib/typelib.cxx | 4 +-
main/cppu/source/uno/EnvStack.cxx | 4 +-
main/cppu/source/uno/lbenv.cxx | 8 +-
main/cppu/source/uno/lbmap.cxx | 6 +-
main/cppuhelper/source/component_context.cxx | 6 +-
main/cppuhelper/source/interfacecontainer.cxx | 2 +-
main/crashrep/source/unx/main.cxx | 26 +++---
main/crashrep/source/win32/soreport.cpp | 10 +--
main/cui/source/customize/cfg.cxx | 6 +-
main/cui/source/inc/macropg.hxx | 4 +-
main/cui/source/inc/scriptdlg.hxx | 4 +-
main/dbaccess/source/core/inc/column.hxx | 4 +-
.../source/core/recovery/subcomponents.hxx | 4 +-
.../source/ui/app/subcomponentmanager.cxx | 2 +-
.../source/ui/browser/genericcontroller.cxx | 4 +-
main/desktop/source/app/app.cxx | 2 +-
main/desktop/source/app/dispatchwatcher.hxx | 4 +-
.../deployment/manager/dp_activepackages.cxx | 2 +-
.../manager/dp_extensionmanager.cxx | 1 +
.../registry/component/dp_component.cxx | 4 +-
.../deployment/registry/dp_registry.cxx | 10 +--
.../source/migration/migration_impl.hxx | 4 +-
main/embedserv/source/inc/embeddoc.hxx | 6 +-
.../source/bibliography/framectr.cxx | 4 +-
main/extensions/source/ole/oleobjw.cxx | 8 +-
main/extensions/source/ole/oleobjw.hxx | 6 +-
.../source/ole/unoconversionutilities.hxx | 26 +++---
main/extensions/source/ole/unoobjw.cxx | 4 +-
main/extensions/source/ole/unoobjw.hxx | 6 +-
.../source/propctrlr/browserlistbox.hxx | 4 +-
.../source/propctrlr/eventhandler.cxx | 2 +-
.../source/propctrlr/eventhandler.hxx | 2 +-
.../source/propctrlr/pcrcommontypes.hxx | 4 +-
.../source/propctrlr/propcontroller.hxx | 8 +-
main/filter/inc/filter/msfilter/msocximex.hxx | 4 +-
main/filter/source/config/cache/cacheitem.hxx | 6 +-
.../source/config/cache/filtercache.cxx | 2 +-
.../source/config/cache/querytokenizer.hxx | 4 +-
main/filter/source/msfilter/svxmsbas.cxx | 4 +-
main/filter/source/svg/svgfilter.hxx | 4 +-
main/forms/source/component/DatabaseForm.cxx | 2 +-
main/forms/source/component/Filter.hxx | 4 +-
main/forms/source/inc/InterfaceContainer.hxx | 4 +-
main/formula/inc/formula/FormulaCompiler.hxx | 6 +-
.../source/win32/filepicker/propmap.hxx | 4 +-
.../framework/inc/classes/filtercachedata.hxx | 6 +-
main/framework/inc/framework/titlehelper.hxx | 2 +-
.../inc/services/substitutepathvars.hxx | 6 +-
main/framework/inc/stdtypes.h | 2 +-
.../inc/uiconfiguration/globalsettings.hxx | 2 +-
.../inc/uiconfiguration/imagemanager.hxx | 2 +-
.../inc/uiconfiguration/imagetype.hxx | 6 +-
.../uiconfiguration/moduleimagemanager.hxx | 2 +-
.../uiconfiguration/moduleuicfgsupplier.hxx | 4 +-
.../moduleuiconfigurationmanager.hxx | 6 +-
.../uiconfiguration/uicategorydescription.hxx | 2 +-
.../uiconfigurationmanager.hxx | 6 +-
.../windowstateconfiguration.hxx | 6 +-
.../inc/uielement/menubarwrapper.hxx | 2 +-
.../inc/uielement/newmenucontroller.hxx | 4 +-
.../inc/uielement/uicommanddescription.hxx | 6 +-
.../inc/xml/eventsdocumenthandler.hxx | 4 +-
.../inc/xml/imagesdocumenthandler.hxx | 4 +-
.../inc/xml/statusbardocumenthandler.hxx | 4 +-
.../source/fwe/classes/addonsoptions.cxx | 8 +-
main/framework/source/services/desktop.cxx | 2 +-
main/framework/source/services/frame.cxx | 2 +-
.../uiconfiguration/imagemanagerimpl.hxx | 4 +-
.../uiconfiguration/moduleuicfgsupplier.cxx | 2 +-
.../moduleuiconfigurationmanager.cxx | 8 +-
.../uiconfiguration/uicategorydescription.cxx | 2 +-
.../uiconfigurationmanager.cxx | 4 +-
.../uiconfigurationmanagerimpl.cxx | 8 +-
.../uiconfigurationmanagerimpl.hxx | 6 +-
.../windowstateconfiguration.cxx | 2 +-
.../source/uielement/newmenucontroller.cxx | 2 +-
.../uielement/toolbarsmenucontroller.cxx | 2 +-
.../source/uielement/uicommanddescription.cxx | 2 +-
main/framework/test/typecfg/cfgview.cxx | 2 +-
main/idlc/inc/idlc/idlctypes.hxx | 4 +-
main/idlc/inc/idlc/options.hxx | 2 +-
main/io/source/acceptor/acc_socket.cxx | 4 +-
main/io/source/connector/connector.hxx | 4 +-
main/io/source/stm/odata.cxx | 4 +-
main/l10ntools/inc/cfgmerge.hxx | 4 +-
main/l10ntools/inc/export.hxx | 10 +--
main/l10ntools/inc/inireader.hxx | 8 +-
main/l10ntools/inc/tagtest.hxx | 4 +-
main/l10ntools/inc/xmlparse.hxx | 10 +--
main/l10ntools/source/help/HelpCompiler.hxx | 6 +-
main/l10ntools/source/help/HelpLinker.cxx | 2 +-
main/linguistic/source/convdic.hxx | 6 +-
.../complextoolbarcontrols/ListenerHelper.h | 6 +-
main/oox/inc/oox/export/shapes.hxx | 4 +-
.../source/drawingml/customshapegeometry.cxx | 4 +-
main/oox/source/export/shapes.cxx | 4 +-
main/package/inc/HashMaps.hxx | 8 +-
.../package/manifest/ManifestImport.hxx | 2 +-
.../ZipPackageFolderEnumeration.hxx | 2 +-
.../package/source/xstor/ohierarchyholder.hxx | 4 +-
main/padmin/source/adddlg.cxx | 4 +-
main/padmin/source/fontentry.cxx | 6 +-
main/padmin/source/fontentry.hxx | 4 +-
main/padmin/source/prtsetup.cxx | 4 +-
main/pyuno/source/module/pyuno_impl.hxx | 12 +--
main/rdbmaker/inc/codemaker/dependency.hxx | 6 +-
main/rdbmaker/inc/codemaker/options.hxx | 4 +-
main/rdbmaker/inc/codemaker/typemanager.hxx | 4 +-
main/registry/source/regimpl.hxx | 4 +-
main/reportdesign/source/core/sdr/UndoEnv.cxx | 2 +-
main/rsc/inc/rschash.hxx | 6 +-
main/rsc/source/parser/rscibas.cxx | 4 +-
main/rsc/source/parser/rsclex.cxx | 2 +-
main/rsc/source/parser/rsclex.hxx | 4 +-
main/rsc/source/tools/rschash.cxx | 4 +-
main/sal/inc/osl/diagnose.hxx | 4 +-
main/sal/inc/rtl/string.hxx | 4 +-
main/sal/inc/rtl/ustring.hxx | 4 +-
main/sal/rtl/source/bootstrap.cxx | 4 +-
main/sal/rtl/source/hash.cxx | 4 +-
main/sal/rtl/source/unload.cxx | 6 +-
main/sax/source/fastparser/fastparser.hxx | 4 +-
main/sc/inc/addincol.hxx | 4 +-
main/sc/inc/autonamecache.hxx | 4 +-
main/sc/inc/chart2uno.hxx | 6 +-
main/sc/inc/chartlis.hxx | 6 +-
main/sc/inc/compiler.hxx | 2 +-
main/sc/inc/dpcachetable.hxx | 10 +--
main/sc/inc/dpglobal.hxx | 2 +-
main/sc/inc/dpgroup.hxx | 8 +-
main/sc/inc/dpsave.hxx | 6 +-
main/sc/inc/dpsdbtab.hxx | 4 +-
main/sc/inc/dpshttab.hxx | 4 +-
main/sc/inc/dptabdat.hxx | 8 +-
main/sc/inc/dptabres.hxx | 10 +--
main/sc/inc/dptabsrc.hxx | 6 +-
main/sc/inc/externalrefmgr.hxx | 30 +++----
main/sc/inc/formulaparserpool.hxx | 4 +-
main/sc/inc/global.hxx | 2 +-
main/sc/inc/linkuno.hxx | 2 +-
main/sc/inc/lookupcache.hxx | 6 +-
main/sc/inc/sheetdata.hxx | 4 +-
main/sc/source/core/data/bcaslot.cxx | 2 +-
main/sc/source/core/data/dpcachetable.cxx | 10 +--
main/sc/source/core/data/dpgroup.cxx | 16 ++--
main/sc/source/core/data/dpsave.cxx | 12 +--
main/sc/source/core/data/dpsdbtab.cxx | 12 +--
main/sc/source/core/data/dpshttab.cxx | 12 +--
main/sc/source/core/data/dptabres.cxx | 6 +-
main/sc/source/core/data/dptabsrc.cxx | 18 ++--
main/sc/source/core/inc/bcaslot.hxx | 6 +-
main/sc/source/core/inc/cellkeytranslator.hxx | 4 +-
.../sc/source/core/tool/cellkeytranslator.cxx | 2 +-
main/sc/source/core/tool/chartlis.cxx | 12 +--
.../sc/source/core/tool/formulaparserpool.cxx | 2 +-
main/sc/source/filter/inc/namebuff.hxx | 4 +-
main/sc/source/filter/xml/sheetdata.cxx | 2 +-
main/sc/source/filter/xml/xmldpimp.hxx | 4 +-
main/sc/source/filter/xml/xmlexprt.hxx | 4 +-
main/sc/source/filter/xml/xmlimprt.hxx | 4 +-
main/sc/source/ui/cctrl/dpcontrol.cxx | 6 +-
main/sc/source/ui/inc/crnrdlg.hxx | 4 +-
main/sc/source/ui/inc/docsh.hxx | 4 +-
main/sc/source/ui/inc/dpcontrol.hxx | 4 +-
main/sc/source/ui/inc/pvfundlg.hxx | 4 +-
main/sc/source/ui/unoobj/cellsuno.cxx | 4 +-
main/sc/source/ui/unoobj/chart2uno.cxx | 13 +--
main/sc/source/ui/vba/vbachartobjects.hxx | 4 +-
main/sc/source/ui/vba/vbacharts.hxx | 2 +-
main/sc/source/ui/vba/vbawindow.cxx | 4 +-
main/sc/source/ui/vba/vbawindows.cxx | 4 +-
main/sc/source/ui/vba/vbaworkbooks.cxx | 2 +-
main/sc/source/ui/view/dbfunc3.cxx | 14 +--
main/sc/source/ui/view/gridwin2.cxx | 8 +-
main/scripting/source/dlgprov/dlgevtatt.hxx | 4 +-
.../source/provider/ActiveMSPList.hxx | 4 +-
.../source/provider/BrowseNodeFactoryImpl.cxx | 2 +-
.../source/provider/ProviderCache.hxx | 4 +-
main/scripting/source/storage/ScriptData.hxx | 8 +-
main/scripting/source/storage/ScriptInfo.cxx | 4 +-
.../source/storage/ScriptSecurityManager.hxx | 4 +-
.../source/storage/ScriptStorage.hxx | 10 +--
.../source/storage/ScriptStorageManager.cxx | 2 +-
.../source/storage/ScriptStorageManager.hxx | 4 +-
.../source/stringresource/stringresource.hxx | 6 +-
.../source/vbaevents/eventhelper.cxx | 6 +-
main/sd/inc/CustomAnimationPreset.hxx | 8 +-
main/sd/inc/TransitionPreset.hxx | 4 +-
.../ConfigurationControllerBroadcaster.hxx | 4 +-
.../configuration/ResourceFactoryManager.hxx | 4 +-
.../ui/framework/module/ModuleController.cxx | 6 +-
.../ui/framework/tools/FrameworkHelper.cxx | 2 +-
.../source/ui/sidebar/MasterPageObserver.cxx | 4 +-
.../ui/slidesorter/cache/SlsBitmapCache.cxx | 2 +-
.../ui/slidesorter/cache/SlsBitmapCache.hxx | 2 +-
.../slidesorter/cache/SlsPageCacheManager.cxx | 2 +-
main/sd/source/ui/tools/IconCache.cxx | 4 +-
main/sd/source/ui/unoidl/facreg.cxx | 4 +-
main/sd/source/ui/view/ViewShellManager.cxx | 6 +-
.../source/minimizer/pppoptimizertoken.cxx | 4 +-
main/sdext/source/pdfimport/filterdet.cxx | 4 +-
.../sdext/source/pdfimport/inc/pdfihelper.hxx | 4 +-
main/sdext/source/pdfimport/inc/pdfparse.hxx | 4 +-
.../source/pdfimport/pdfparse/pdfentries.cxx | 8 +-
.../source/pdfimport/sax/saxattrlist.cxx | 6 +-
.../source/pdfimport/sax/saxattrlist.hxx | 6 +-
main/sdext/source/pdfimport/test/pdfunzip.cxx | 4 +-
main/sdext/source/pdfimport/test/tests.cxx | 10 +--
.../source/pdfimport/tree/imagecontainer.hxx | 2 +-
.../source/pdfimport/tree/pdfiprocessor.hxx | 10 +--
main/sdext/source/pdfimport/tree/style.cxx | 14 +--
main/sdext/source/pdfimport/tree/style.hxx | 14 +--
.../source/pdfimport/wrapper/wrapper.cxx | 4 +-
.../pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx | 2 +-
.../pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx | 4 +-
.../presenter/PresenterProtocolHandler.hxx | 2 +-
.../win32/customactions/rebase/rebase.cxx | 4 +-
main/sfx2/inc/sfx2/sidebar/Theme.hxx | 4 +-
main/sfx2/source/appl/imagemgr.cxx | 4 +-
main/sfx2/source/appl/newhelp.cxx | 4 +-
main/sfx2/source/appl/workwin.cxx | 4 +-
main/sfx2/source/control/bindings.cxx | 4 +-
main/sfx2/source/doc/Metadatable.cxx | 14 +--
main/sfx2/source/inc/objshimp.hxx | 2 +-
main/sfx2/source/toolbox/imgmgr.cxx | 4 +-
main/sfx2/source/view/sfxbasecontroller.cxx | 4 +-
.../source/engine/eventmultiplexer.cxx | 2 +-
.../source/engine/slide/layermanager.hxx | 4 +-
main/sot/source/sdstor/stgcache.cxx | 4 +-
main/stoc/source/corereflection/base.hxx | 6 +-
main/stoc/source/corereflection/lrucache.hxx | 4 +-
main/stoc/source/inspect/introspection.cxx | 12 +--
.../invocation_adapterfactory/iafactory.cxx | 8 +-
.../source/namingservice/namingservice.cxx | 4 +-
main/stoc/source/security/file_policy.cxx | 4 +-
.../source/servicemanager/servicemanager.cxx | 12 +--
main/stoc/source/tdmanager/lrucache.hxx | 4 +-
.../svgio/inc/svgio/svgreader/svgdocument.hxx | 4 +-
main/svgio/inc/svgio/svgreader/svgnode.hxx | 2 +-
main/svgio/inc/svgio/svgreader/svgtoken.hxx | 2 +-
main/svgio/source/svgreader/svgtoken.cxx | 2 +-
main/svgio/source/svgreader/svgtools.cxx | 4 +-
main/svl/inc/pch/precompiled_svl.hxx | 2 +-
main/svl/source/items/itemprop.cxx | 4 +-
main/svtools/inc/pch/precompiled_svtools.hxx | 2 +-
.../inc/svtools/framestatuslistener.hxx | 4 +-
.../inc/svtools/statusbarcontroller.hxx | 4 +-
.../svtools/inc/svtools/toolboxcontroller.hxx | 4 +-
.../source/table/cellvalueconversion.cxx | 4 +-
.../source/uno/framestatuslistener.cxx | 2 +-
.../source/uno/statusbarcontroller.cxx | 2 +-
main/svtools/source/uno/toolboxcontroller.cxx | 2 +-
main/svx/inc/svx/ShapeTypeHandler.hxx | 4 +-
main/svx/inc/svx/sdasitm.hxx | 6 +-
.../EnhancedCustomShapeTypeNames.cxx | 6 +-
main/svx/source/inc/DGColorNameLookUp.hxx | 4 +-
.../svx/source/table/accessibletableshape.cxx | 2 +-
main/svx/source/table/propertyset.hxx | 4 +-
.../source/unodraw/shapepropertynotifier.cxx | 4 +-
main/sw/inc/IDocumentExternalData.hxx | 4 +-
main/sw/inc/SwStyleNameMapper.hxx | 4 +-
main/sw/inc/dbgoutsw.hxx | 8 +-
main/sw/inc/doc.hxx | 6 +-
main/sw/inc/numrule.hxx | 8 +-
main/sw/inc/swwait.hxx | 2 +-
main/sw/source/core/access/accpara.hxx | 4 +-
main/sw/source/core/doc/docnew.cxx | 4 +-
main/sw/source/core/doc/docnum.cxx | 4 +-
main/sw/source/core/doc/number.cxx | 4 +-
main/sw/source/core/doc/swstylemanager.cxx | 4 +-
main/sw/source/core/inc/layouter.hxx | 4 +-
main/sw/source/filter/ww8/WW8TableInfo.hxx | 8 +-
main/sw/source/filter/ww8/hash_wrap.hxx | 10 +--
main/sw/source/filter/ww8/wrtww8.cxx | 2 +-
main/sw/source/filter/ww8/ww8par.cxx | 4 +-
main/sw/source/filter/xml/xmlimp.cxx | 4 +-
main/sw/source/filter/xml/xmltbli.cxx | 2 +-
main/sw/source/filter/xml/xmltbli.hxx | 4 +-
.../source/ui/vba/vbadocumentproperties.cxx | 6 +-
.../source/ui/vba/vbadocumentproperties.hxx | 2 +-
main/sw/source/ui/vba/vbadocuments.cxx | 2 +-
main/sw/source/ui/vba/vbafont.cxx | 4 +-
main/testtools/source/performance/ubtest.cxx | 4 +-
.../inc/toolkit/controls/eventcontainer.hxx | 4 +-
.../source/controls/geometrycontrolmodel.cxx | 2 +-
main/toolkit/source/layout/core/import.hxx | 4 +-
main/toolkit/source/layout/core/root.hxx | 4 +-
main/tools/inc/tools/pstm.hxx | 4 +-
main/tools/source/rc/resmgr.cxx | 18 ++--
main/ucb/source/core/ucbstore.cxx | 4 +-
main/ucb/source/ucp/file/filnot.hxx | 4 +-
main/ucb/source/ucp/file/filtask.hxx | 4 +-
main/ucb/source/ucp/file/shell.hxx | 8 +-
.../ucp/hierarchy/hierarchyprovider.hxx | 4 +-
main/ucb/source/ucp/package/pkgprovider.cxx | 4 +-
.../source/ucp/webdav/ContentProperties.hxx | 4 +-
main/ucb/source/ucp/webdav/CurlSession.cxx | 2 +-
main/ucb/source/ucp/webdav/PropertyMap.hxx | 4 +-
.../ucp/webdav/webdavresponseparser.cxx | 6 +-
.../cachemap/cachemapobjectcontainer2.hxx | 4 +-
.../source/provider/contenthelper.cxx | 4 +-
.../source/provider/providerhelper.cxx | 4 +-
.../inc/unodevtools/typemanager.hxx | 4 +-
.../source/skeletonmaker/cppcompskeleton.cxx | 50 +++++------
.../source/skeletonmaker/javacompskeleton.cxx | 28 +++---
.../source/skeletonmaker/skeletoncommon.cxx | 28 +++---
.../source/skeletonmaker/skeletoncommon.hxx | 20 ++---
main/unotools/inc/unotools/atom.hxx | 8 +-
main/unotools/inc/unotools/eventcfg.hxx | 4 +-
main/unotools/inc/unotools/fontcfg.hxx | 12 +--
main/unotools/source/config/cmdoptions.cxx | 8 +-
main/unotools/source/config/eventcfg.cxx | 2 +-
.../source/config/extendedsecurityoptions.cxx | 4 +-
main/unotools/source/config/fontcfg.cxx | 6 +-
main/unotools/source/config/optionsdlg.cxx | 4 +-
main/unotools/source/config/pathoptions.cxx | 8 +-
main/unotools/source/config/viewoptions.cxx | 4 +-
main/unotools/source/misc/atom.cxx | 26 +++---
main/unotools/source/misc/fontdefs.cxx | 4 +-
main/unoxml/source/dom/node.hxx | 4 +-
main/uui/source/iahndl.hxx | 4 +-
.../aqua/source/dtrans/DataFlavorMapping.hxx | 4 +-
main/vcl/aqua/source/gdi/atsfonts.cxx | 4 +-
main/vcl/aqua/source/gdi/atslayout.hxx | 2 +-
main/vcl/aqua/source/gdi/ctfonts.cxx | 2 +-
main/vcl/inc/aqua/saldata.hxx | 4 +-
main/vcl/inc/cupsmgr.hxx | 6 +-
main/vcl/inc/fontcache.hxx | 6 +-
main/vcl/inc/glyphcache.hxx | 10 +--
main/vcl/inc/graphite_cache.hxx | 8 +-
main/vcl/inc/impimagetree.hxx | 6 +-
main/vcl/inc/os2/salgdi.h | 4 +-
main/vcl/inc/outfont.hxx | 6 +-
main/vcl/inc/printergfx.hxx | 4 +-
main/vcl/inc/svdata.hxx | 4 +-
main/vcl/inc/unx/saldisp.hxx | 4 +-
main/vcl/inc/vcl/configsettings.hxx | 6 +-
main/vcl/inc/vcl/fontmanager.hxx | 36 ++++----
main/vcl/inc/vcl/lazydelete.hxx | 4 +-
main/vcl/inc/vcl/ppdparser.hxx | 10 +--
main/vcl/inc/vcl/print.hxx | 4 +-
main/vcl/inc/vcl/printerinfomanager.hxx | 10 +--
main/vcl/inc/win/salgdi.h | 4 +-
main/vcl/os2/source/gdi/os2layout.cxx | 4 +-
main/vcl/source/control/tabctrl.cxx | 10 +--
main/vcl/source/gdi/configsettings.cxx | 4 +-
main/vcl/source/gdi/impimagetree.cxx | 2 +-
main/vcl/source/gdi/pdfwriter_impl.cxx | 16 ++--
main/vcl/source/gdi/pdfwriter_impl.hxx | 12 +--
main/vcl/source/gdi/print.cxx | 8 +-
main/vcl/source/gdi/print3.cxx | 28 +++---
main/vcl/source/glyphs/gcach_ftyp.cxx | 4 +-
main/vcl/source/glyphs/gcach_ftyp.hxx | 8 +-
main/vcl/source/glyphs/graphite_adaptors.cxx | 2 +-
main/vcl/source/helper/canvastools.cxx | 6 +-
main/vcl/unx/generic/dtrans/X11_selection.cxx | 54 ++++++------
main/vcl/unx/generic/dtrans/X11_selection.hxx | 14 +--
main/vcl/unx/generic/dtrans/X11_service.cxx | 6 +-
.../unx/generic/fontmanager/fontconfig.cxx | 12 +--
.../unx/generic/fontmanager/fontmanager.cxx | 86 +++++++++----------
main/vcl/unx/generic/gdi/pspgraphics.cxx | 2 +-
main/vcl/unx/generic/gdi/salgdi3.cxx | 2 +-
main/vcl/unx/generic/gdi/salprnpsp.cxx | 8 +-
main/vcl/unx/generic/printer/cupsmgr.cxx | 20 ++---
main/vcl/unx/generic/printer/ppdparser.cxx | 14 +--
.../generic/printer/printerinfomanager.cxx | 38 ++++----
.../vcl/unx/generic/printergfx/common_gfx.cxx | 10 +--
main/vcl/unx/generic/printergfx/glyphset.hxx | 6 +-
main/vcl/unx/generic/printergfx/text_gfx.cxx | 4 +-
main/vcl/unx/gtk/a11y/atkeditabletext.cxx | 2 +-
main/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx | 4 +-
main/vcl/unx/headless/svpelement.cxx | 6 +-
main/vcl/unx/headless/svpprn.cxx | 8 +-
main/vcl/unx/headless/svppspgraphics.cxx | 2 +-
main/vcl/win/source/app/salinfo.cxx | 6 +-
main/vcl/win/source/gdi/winlayout.cxx | 4 +-
.../source/service/msaaservice_impl.cxx | 2 +-
.../inc/resourcemodel/TagLogger.hxx | 2 +-
.../inc/resourcemodel/XPathLogger.hxx | 6 +-
.../qa/cppunittests/qname/testQName.cxx | 2 +-
.../source/dmapper/DomainMapper_Impl.hxx | 2 +-
.../source/dmapper/PropertyIds.hxx | 4 +-
.../source/doctok/WW8BinTableImpl.hxx | 4 +-
.../writerfilter/source/doctok/WW8CpAndFc.hxx | 4 +-
.../source/doctok/WW8DocumentImpl.hxx | 6 +-
.../source/ooxml/OOXMLFactory.hxx | 20 ++---
.../source/resourcemodel/TagLogger.cxx | 2 +-
.../source/resourcemodel/WW8Analyzer.hxx | 4 +-
.../doctok/DocTokAnalyzeService.cxx | 2 +-
.../doctok/DocTokTestService.cxx | 2 +-
.../ooxml/OOXMLAnalyzeService.cxx | 2 +-
.../debugservices/ooxml/OOXMLTestService.cxx | 2 +-
.../rtftok/ScannerTestService.cxx | 4 +-
.../debugservices/rtftok/XMLScanner.cxx | 2 +-
.../source/cxxhelp/provider/databases.hxx | 20 ++---
main/xmlhelp/source/cxxhelp/provider/db.hxx | 6 +-
main/xmloff/inc/StyleMap.hxx | 4 +-
.../inc/xmloff/SinglePropertySetInfoCache.hxx | 4 +-
main/xmloff/inc/xmloff/nmspmap.hxx | 6 +-
main/xmloff/inc/xmloff/prstylei.hxx | 4 +-
main/xmloff/source/core/nmspmap.cxx | 2 +-
.../source/draw/EnhancedCustomShapeToken.cxx | 4 +-
main/xmloff/source/draw/ximpcustomshape.cxx | 4 +-
.../source/forms/property_meta_data.cxx | 10 +--
main/xmloff/source/style/xmlexppr.cxx | 4 +-
main/xmloff/source/text/txtparae.cxx | 4 +-
.../source/transform/EventOASISTContext.cxx | 4 +-
.../source/transform/EventOOoTContext.cxx | 4 +-
.../source/transform/TransformerActions.hxx | 4 +-
.../source/transform/TransformerTokenMap.hxx | 4 +-
.../source/xml_helper/xml_impctx.cxx | 8 +-
479 files changed, 1342 insertions(+), 1340 deletions(-)
diff --git a/main/accessibility/inc/accessibility/extended/textwindowaccessibility.hxx b/main/accessibility/inc/accessibility/extended/textwindowaccessibility.hxx
index aec4d3809a6..6b29dfb31a7 100644
--- a/main/accessibility/inc/accessibility/extended/textwindowaccessibility.hxx
+++ b/main/accessibility/inc/accessibility/extended/textwindowaccessibility.hxx
@@ -69,7 +69,7 @@
#endif
#include
#include
-#include
+#include
class TextEngine;
class TextView;
@@ -343,7 +343,7 @@ private:
};
-typedef ::std::hash_map< ::rtl::OUString,
+typedef ::std::unordered_map< ::rtl::OUString,
::css::beans::PropertyValue,
::rtl::OUStringHash,
::std::equal_to< ::rtl::OUString > > tPropValMap;
diff --git a/main/accessibility/source/extended/textwindowaccessibility.cxx b/main/accessibility/source/extended/textwindowaccessibility.cxx
index 900c63b818c..505cbcb9d1f 100644
--- a/main/accessibility/source/extended/textwindowaccessibility.cxx
+++ b/main/accessibility/source/extended/textwindowaccessibility.cxx
@@ -35,7 +35,7 @@
#include
#include
-#include
+#include
namespace css = ::com::sun::star;
diff --git a/main/animations/source/animcore/targetpropertiescreator.cxx b/main/animations/source/animcore/targetpropertiescreator.cxx
index b7f9591a2c8..d6304eb7e3a 100644
--- a/main/animations/source/animcore/targetpropertiescreator.cxx
+++ b/main/animations/source/animcore/targetpropertiescreator.cxx
@@ -44,7 +44,7 @@
#include
#include
-#include
+#include
using namespace ::com::sun::star;
@@ -136,7 +136,7 @@ namespace animcore
*/
sal_Int16 mnParagraphIndex;
- /// Comparison needed for hash_map
+ /// Comparison needed for unordered_map
bool operator==( const ShapeHashKey& rRHS ) const
{
return mxRef == rRHS.mxRef && mnParagraphIndex == rRHS.mnParagraphIndex;
@@ -165,7 +165,7 @@ namespace animcore
};
// A hash map which maps a XShape to the corresponding vector of initial properties
- typedef ::std::hash_map< ShapeHashKey, VectorOfNamedValues, ShapeKeyHasher > XShapeHash;
+ typedef ::std::unordered_map< ShapeHashKey, VectorOfNamedValues, ShapeKeyHasher > XShapeHash;
class NodeFunctor
{
diff --git a/main/avmedia/source/macavf/macavf_player.cxx b/main/avmedia/source/macavf/macavf_player.cxx
index 57865396ac4..41807123215 100644
--- a/main/avmedia/source/macavf/macavf_player.cxx
+++ b/main/avmedia/source/macavf/macavf_player.cxx
@@ -28,8 +28,8 @@
using namespace ::com::sun::star;
-#include
-typedef std::hash_map HandlersForObject;
+#include
+typedef std::unordered_map HandlersForObject;
@implementation MacAVObserverObject
{
diff --git a/main/basctl/source/inc/bastypes.hxx b/main/basctl/source/inc/bastypes.hxx
index e1ac6b609e3..8d08327169a 100644
--- a/main/basctl/source/inc/bastypes.hxx
+++ b/main/basctl/source/inc/bastypes.hxx
@@ -48,7 +48,7 @@ class SfxItemSet;
#include
#include
-#include
+#include
#define LINE_SEP_CR 0x0D
#define LINE_SEP 0x0A
@@ -305,7 +305,7 @@ private:
}
};
- typedef ::std::hash_map< LibInfoKey, LibInfoItem*, LibInfoKeyHash, ::std::equal_to< LibInfoKey > > LibInfoMap;
+ typedef ::std::unordered_map< LibInfoKey, LibInfoItem*, LibInfoKeyHash, ::std::equal_to< LibInfoKey > > LibInfoMap;
LibInfoMap m_aLibInfoMap;
public:
diff --git a/main/basic/source/classes/sb.cxx b/main/basic/source/classes/sb.cxx
index a7efe347ca2..5edd20be12d 100644
--- a/main/basic/source/classes/sb.cxx
+++ b/main/basic/source/classes/sb.cxx
@@ -58,7 +58,7 @@
#include
#include "errobject.hxx"
#include