MCPcopy Create free account
hub / github.com/BVLC/caffe / CStringEquals

Method CStringEquals

src/gtest/gtest-all.cpp:2198–2204  ·  view source on GitHub ↗

Compares two C strings. Returns true iff they have the same content. Unlike strcmp(), this function can handle NULL argument(s). A NULL C string is considered different to any non-NULL C string, including the empty string.

Source from the content-addressed store, hash-verified

2196// C string is considered different to any non-NULL C string,
2197// including the empty string.
2198bool String::CStringEquals(const char * lhs, const char * rhs) {
2199 if ( lhs == NULL ) return rhs == NULL;
2200
2201 if ( rhs == NULL ) return false;
2202
2203 return strcmp(lhs, rhs) == 0;
2204}
2205
2206#if GTEST_HAS_STD_WSTRING || GTEST_HAS_GLOBAL_WSTRING
2207

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected