diff --git a/src/jrd/SysFunction.cpp b/src/jrd/SysFunction.cpp index 118d49a3a0..1400c08386 100644 --- a/src/jrd/SysFunction.cpp +++ b/src/jrd/SysFunction.cpp @@ -3068,7 +3068,7 @@ dsc* evlEncryptDecrypt(thread_db* tdbb, const SysFunction* function, const NestV if (m) { unsigned blockLen = cipher_descriptor[cipher].block_length; - if (iv.getBytes() && iv.getLength() != blockLen) + if (iv.getLength() && iv.getLength() != blockLen) status_exception::raise(Arg::Gds(isc_tom_iv_length) << Arg::Num(iv.getLength()) << Arg::Num(blockLen)); switch (m->code)