MCPcopy Create free account
hub / github.com/ddnet/ddnet / EscapeJsonChar

Function EscapeJsonChar

src/engine/shared/json.cpp:47–60  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45}
46
47static char EscapeJsonChar(char c)
48{
49 switch(c)
50 {
51 case '\"': return '\"';
52 case '\\': return '\\';
53 case '\b': return 'b';
54 case '\n': return 'n';
55 case '\r': return 'r';
56 case '\t': return 't';
57 // Don't escape '\f', who uses that. :)
58 default: return 0;
59 }
60}
61
62char *EscapeJson(char *pBuffer, int BufferSize, const char *pString)
63{

Callers 1

EscapeJsonFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected