[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - connectivity/source

Lionel Elie Mamane lionel at mamane.lu
Wed Apr 11 21:42:24 UTC 2018


 connectivity/source/commontools/DateConversion.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4bb50524e385803fddc50474667777fcf7ce19e1
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date:   Sun Apr 8 08:26:55 2018 +0200

    SQL string quoting: escape "'" character also at beginning of string
    
    Change-Id: I51db43c1a3b6d3c93a04a3419238ea286cab987e
    Reviewed-on: https://gerrit.libreoffice.org/52578
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>

diff --git a/connectivity/source/commontools/DateConversion.cxx b/connectivity/source/commontools/DateConversion.cxx
index 435a0cc21d19..4527fa6b4493 100644
--- a/connectivity/source/commontools/DateConversion.cxx
+++ b/connectivity/source/commontools/DateConversion.cxx
@@ -81,7 +81,7 @@ OUString DBTypeConversion::toSQLString(sal_Int32 eType, const Any& _rVal, bool b
                     {
                         OUString aTemp;
                         _rxTypeConverter->convertToSimpleType(_rVal, TypeClass_STRING) >>= aTemp;
-                        sal_Int32 nIndex = (sal_Int32)-1;
+                        sal_Int32 nIndex = (sal_Int32)-2;
                         const OUString sQuot("\'");
                         do
                         {


More information about the Libreoffice-commits mailing list