summaryrefslogtreecommitdiffstats
path: root/connectivity/source/drivers/firebird/Util.cxx
diff options
context:
space:
mode:
authorLionel Elie Mamane <lionel@mamane.lu>2015-12-18 16:54:00 +0100
committerLionel Elie Mamane <lionel@mamane.lu>2015-12-18 16:57:42 +0100
commit85f17f9ea822421c6d31da90d7be83089f58cec2 (patch)
tree5d7a184db3f325709d2236919a2c766b8c39be44 /connectivity/source/drivers/firebird/Util.cxx
parentdbaccess: module_dba not used anymore (diff)
downloadcore-85f17f9ea822421c6d31da90d7be83089f58cec2.tar.gz
core-85f17f9ea822421c6d31da90d7be83089f58cec2.zip
tdf#96572 firebird correctly transmit request for NULL
even if column is not nullable Change-Id: I72ceda68e983125aef26c8f0aacc06320bd16b77
Diffstat (limited to 'connectivity/source/drivers/firebird/Util.cxx')
-rw-r--r--connectivity/source/drivers/firebird/Util.cxx16
1 files changed, 5 insertions, 11 deletions
diff --git a/connectivity/source/drivers/firebird/Util.cxx b/connectivity/source/drivers/firebird/Util.cxx
index ddb9d022c3e9..00eb4aa3f62e 100644
--- a/connectivity/source/drivers/firebird/Util.cxx
+++ b/connectivity/source/drivers/firebird/Util.cxx
@@ -254,11 +254,8 @@ void firebird::mallocSQLVAR(XSQLDA* pSqlda)
assert(false);
break;
}
- if (pVar->sqltype & 1)
- {
- /* allocate variable to hold NULL status */
- pVar->sqlind = static_cast<short *>(malloc(sizeof(short)));
- }
+ /* allocate variable to hold NULL status */
+ pVar->sqlind = static_cast<short *>(malloc(sizeof(short)));
}
}
@@ -302,13 +299,10 @@ void firebird::freeSQLVAR(XSQLDA* pSqlda)
break;
}
- if (pVar->sqltype & 1)
+ if(pVar->sqlind)
{
- if(pVar->sqlind)
- {
- free(pVar->sqlind);
- pVar->sqlind = nullptr;
- }
+ free(pVar->sqlind);
+ pVar->sqlind = nullptr;
}
}
}