Skip to content

Commit 44da3ac

Browse files
Ev3nthvlad
authored andcommitted
Fixed crash after calling incorrectly parametrized request (#8666)
* Fixed crash after calling incorrectly parametrized request * Patch: Fixed crash after calling incorrectly parametrized request
1 parent 1e5adbf commit 44da3ac

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/jrd/extds/ExtDS.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2239,6 +2239,12 @@ void Statement::setInParams(thread_db* tdbb, const MetaName* const* names,
22392239
const FB_SIZE_T excCount = in_excess ? in_excess->getCount() : 0;
22402240
const FB_SIZE_T sqlCount = m_sqlParamNames.getCount();
22412241

2242+
if (m_error = (!names && sqlCount))
2243+
{
2244+
// Parameter name expected
2245+
ERR_post(Arg::Gds(isc_eds_prm_name_expected));
2246+
}
2247+
22422248
// OK : count - excCount <= sqlCount <= count
22432249

22442250
// Check if all passed named parameters, not marked as excess, are present in query text

0 commit comments

Comments
 (0)