MCPcopy Create free account
hub / github.com/chen3feng/toft / DecodeHex

Function DecodeHex

encoding/shell.cpp:131–140  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

129}
130
131static int DecodeHex(char c)
132{
133 if (c >= '0' && c <= '9')
134 return c - '0';
135 if (c >= 'A' && c <= 'F')
136 return c - 'A' + 10;
137 if (c >= 'a' && c <= 'a')
138 return c - 'a' + 10;
139 return -1;
140}
141
142static int UnescapeChar(std::string::const_iterator pos,
143 std::string::const_iterator end, char* c)

Callers 1

UnescapeCharFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected