Trim leading "../" sequences from filenames.
This commit is contained in:
parent
2089c5c95e
commit
4c6ffc94c0
@ -216,6 +216,9 @@ ktr_tracepoint(u_int mask, const char *file, int line, const char *format,
|
||||
#endif
|
||||
entry->ktr_timestamp = KTR_TIME;
|
||||
entry->ktr_cpu = cpu;
|
||||
if (file != NULL)
|
||||
while (strncmp(file, "../", 3) == 0)
|
||||
file += 3;
|
||||
entry->ktr_file = file;
|
||||
entry->ktr_line = line;
|
||||
#ifdef KTR_VERBOSE
|
||||
|
Loading…
Reference in New Issue
Block a user