MCPcopy Create free account
hub / github.com/ddopson/node-segfault-handler / buildFileName

Function buildFileName

src/segfault-handler.cpp:181–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

179char logPath[BUFF_SIZE];
180
181static void buildFileName(char sbuff[BUFF_SIZE], int pid) {
182 time_t now;
183
184 // Construct a filename
185 time(&now);
186 if (logPath[0] != '\0') {
187 SNPRINTF(sbuff, BUFF_SIZE, "%s", logPath);
188 } else {
189 SNPRINTF(sbuff, BUFF_SIZE, "stacktrace-%d-%d.log", (int)now, pid);
190 }
191}
192
193SEGFAULT_HANDLER {
194 long address;

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected