MCPcopy Create free account
hub / github.com/Samsung/UTopia / decodePrefixedString

Function decodePrefixedString

external/jsoncpp/jsoncpp.cpp:2552–2561  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2550 return newString;
2551}
2552inline static void decodePrefixedString(bool isPrefixed, char const *prefixed,
2553 unsigned *length, char const **value) {
2554 if (!isPrefixed) {
2555 *length = static_cast<unsigned>(strlen(prefixed));
2556 *value = prefixed;
2557 } else {
2558 *length = *reinterpret_cast<unsigned const *>(prefixed);
2559 *value = prefixed + sizeof(unsigned);
2560 }
2561}
2562/** Free the string duplicated by
2563 * duplicateStringValue()/duplicateAndPrefixStringValue().
2564 */

Callers 9

operator<Method · 0.85
operator==Method · 0.85
asCStringMethod · 0.85
getCStringLengthMethod · 0.85
getStringMethod · 0.85
asStringMethod · 0.85
asConstStringMethod · 0.85
dupPayloadMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected