diff options
-rw-r--r-- | dbaccess/source/core/misc/dsntypes.cxx | 4 | ||||
-rw-r--r-- | dbaccess/source/sdbtools/connection/objectnames.cxx | 12 |
2 files changed, 8 insertions, 8 deletions
diff --git a/dbaccess/source/core/misc/dsntypes.cxx b/dbaccess/source/core/misc/dsntypes.cxx index 57a8ee775501..daa0bc8f3487 100644 --- a/dbaccess/source/core/misc/dsntypes.cxx +++ b/dbaccess/source/core/misc/dsntypes.cxx @@ -314,7 +314,7 @@ OUString ODsnTypeCollection::getEmbeddedDatabase() const DATASOURCE_TYPE ODsnTypeCollection::determineType(const OUString& _rDsn) const { OUString sDsn(comphelper::string::stripEnd(_rDsn, '*')); - sal_Int32 nSeparator = sDsn.indexOf(static_cast<sal_Unicode>(':')); + sal_Int32 nSeparator = sDsn.indexOf(u':'); if (-1 == nSeparator) { if (!sDsn.isEmpty()) @@ -340,7 +340,7 @@ DATASOURCE_TYPE ODsnTypeCollection::determineType(const OUString& _rDsn) const return DST_EMBEDDED_FIREBIRD; // find second : - nSeparator = sDsn.indexOf(static_cast<sal_Unicode>(':'), nSeparator + 1); + nSeparator = sDsn.indexOf(u':', nSeparator + 1); if (-1 == nSeparator) { // at the moment only jdbc is allowed to have just one separator diff --git a/dbaccess/source/sdbtools/connection/objectnames.cxx b/dbaccess/source/sdbtools/connection/objectnames.cxx index 25452bd5a44c..d2026b579fff 100644 --- a/dbaccess/source/sdbtools/connection/objectnames.cxx +++ b/dbaccess/source/sdbtools/connection/objectnames.cxx @@ -161,12 +161,12 @@ namespace sdbtools static ::connectivity::ErrorCondition validateName_getErrorCondition( const OUString& _rName ) { - if ( ( _rName.indexOf( (sal_Unicode)34 ) >= 0 ) // " - || ( _rName.indexOf( (sal_Unicode)39 ) >= 0 ) // ' - || ( _rName.indexOf( (sal_Unicode)96 ) >= 0 ) - || ( _rName.indexOf( (sal_Unicode)145 ) >= 0 ) - || ( _rName.indexOf( (sal_Unicode)146 ) >= 0 ) - || ( _rName.indexOf( (sal_Unicode)180 ) >= 0 ) // removed unparsable chars + if ( ( _rName.indexOf( u'"' ) >= 0 ) + || ( _rName.indexOf( u'\'' ) >= 0 ) + || ( _rName.indexOf( u'`' ) >= 0 ) + || ( _rName.indexOf( u'\x0091' ) >= 0 ) + || ( _rName.indexOf( u'\x0092' ) >= 0 ) + || ( _rName.indexOf( u'\x00B4' ) >= 0 ) // removed unparsable chars ) return ErrorCondition::DB_QUERY_NAME_WITH_QUOTES; |