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

Method compare

src/jrd/MetaName.cpp:40–56  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38namespace Jrd {
39
40int MetaName::compare(const char* s, FB_SIZE_T len) const
41{
42 if (s)
43 {
44 adjustLength(s, len);
45 FB_SIZE_T x = length() < len ? length() : len;
46 int rc = memcmp(c_str(), s, x);
47 if (rc)
48 {
49 return rc;
50 }
51 }
52 else
53 len = 0;
54
55 return length() - len;
56}
57
58void MetaName::adjustLength(const char* const s, FB_SIZE_T& len)
59{

Callers 8

evlLnLog10Function · 0.45
evlLogFunction · 0.45
evlSqrtFunction · 0.45
INTL_compareFunction · 0.45
setupFileMethod · 0.45
greaterThanMethod · 0.45
CVT2_compareFunction · 0.45
CVT2_blob_compareFunction · 0.45

Calls 1

lengthFunction · 0.50

Tested by

no test coverage detected