summaryrefslogtreecommitdiff
path: root/connectivity/source
diff options
context:
space:
mode:
authorLionel Elie Mamane <lionel@mamane.lu>2013-10-14 18:03:32 +0200
committerLionel Elie Mamane <lionel@mamane.lu>2013-10-16 18:45:18 +0200
commitb9fac5769d831989dcff7bd815ca5630a916075d (patch)
tree42dfde9be9d7b74fa8e6a3ce8688dd366391625a /connectivity/source
parente2cec503d214be6b2f6cb64bbafcad8679c7891c (diff)
string->bool conversion recognise "1"/"0" additionally to "true"/"false"
since that is what the conversion in the other direction recognises. It also recognises the "true"/"false" written by LibreOffice versions affected by fdo#68657 Change-Id: I213c23a19e4857905da93eeb2be1b9714215594a
Diffstat (limited to 'connectivity/source')
-rw-r--r--connectivity/source/commontools/FValue.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/connectivity/source/commontools/FValue.cxx b/connectivity/source/commontools/FValue.cxx
index 5a18711c35af..89f1f104d717 100644
--- a/connectivity/source/commontools/FValue.cxx
+++ b/connectivity/source/commontools/FValue.cxx
@@ -1075,12 +1075,12 @@ bool ORowSetValue::getBool() const
const OUString sValue(m_aValue.m_pString);
const static OUString s_sTrue("true");
const static OUString s_sFalse("false");
- if ( sValue.equalsIgnoreAsciiCase(s_sTrue) )
+ if ( sValue.equalsIgnoreAsciiCase(s_sTrue) || (sValue == "1") )
{
bRet = sal_True;
break;
}
- else if ( sValue.equalsIgnoreAsciiCase(s_sFalse) )
+ else if ( sValue.equalsIgnoreAsciiCase(s_sFalse) || (sValue == "0") )
{
bRet = sal_False;
break;