MCPcopy Create free account
hub / github.com/DS-Homebrew/TWiLightMenu / logPrint

Function logPrint

universal/source/common/logging.cpp:37–64  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35}
36
37void logPrint(const char* format, ...) {
38 if (!inited) return;
39
40 va_list args;
41 va_start(args, format);
42 vsnprintf(logText, sizeof(logText), format, args);
43 va_end(args);
44
45 int i = 0;
46 for (i = 0; i < 255; i++) {
47 if (logText[i]==0) {
48 break;
49 }
50 if (logText[i]=='\x5C' && logText[i+1]=='n') {
51 logText[i] = '\x0D';
52 logText[i+1]='\x0A';
53 i++;
54 break;
55 }
56 }
57
58 logFile = fopen(path, "r+");
59 fseek(logFile, position, SEEK_SET);
60 fwrite(logText, 1, i, logFile);
61 fclose(logFile);
62
63 position += i;
64}

Callers 15

fontInitFunction · 0.85
getGameInfoFunction · 0.85
iconUpdateFunction · 0.85
createEsrbSplashFunction · 0.85
dsClassicMenuFunction · 0.85
fontInitFunction · 0.85
graphicsInitFunction · 0.85
getGameInfoFunction · 0.85
iconUpdateFunction · 0.85
checkRomAPFunction · 0.85
createEsrbSplashFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected