MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / getHashAlgorithmDesc

Function getHashAlgorithmDesc

src/jrd/SysFunction.cpp:192–205  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

190
191
192const HashAlgorithmDescriptor* getHashAlgorithmDesc(thread_db* tdbb, const SysFunction* function, const dsc* algDsc, bool* cHash = nullptr)
193{
194 bool cryptHash = (strcmp(function->name, "CRYPT_HASH") == 0);
195 if (cHash)
196 *cHash = cryptHash;
197
198 if (!algDsc->dsc_address || !algDsc->isText())
199 status_exception::raise(Arg::Gds(isc_sysf_invalid_hash_algorithm) << "<not a string constant>");
200
201 MetaName algorithmName;
202 MOV_get_metaname(tdbb, algDsc, algorithmName);
203
204 return HashAlgorithmDescriptor::find(cryptHash ? cryptHashAlgorithmDescriptors : hashAlgorithmDescriptors, algorithmName);
205}
206
207
208// constants

Callers 2

makeHashFunction · 0.85
evlHashFunction · 0.85

Calls 5

raiseFunction · 0.85
GdsClass · 0.85
MOV_get_metanameFunction · 0.85
isTextMethod · 0.80
findFunction · 0.70

Tested by

no test coverage detected