Make some touchups

This commit is contained in:
Justine Tunney 2022-07-15 18:07:34 -07:00
parent 6c49e36537
commit 2e3958c6dc
11 changed files with 161 additions and 63 deletions

View file

@ -51,10 +51,14 @@ relegated void __check_fail(const char *suffix, const char *opstr,
__start_fatal(file, line);
__stpcpy(hostname, "unknown");
gethostname(hostname, sizeof(hostname));
kprintf("check failed on %s pid %d\n", hostname, getpid());
kprintf("\tCHECK_%^s(%s, %s);\n", suffix, wantstr, gotstr);
kprintf("\t\t → %p (%s)\n", want, wantstr);
kprintf("\t\t%s %p (%s)\n", opstr, got, gotstr);
kprintf("check failed on %s pid %d\n"
"\tCHECK_%^s(%s, %s);\n"
"\t\t → %p (%s)\n"
"\t\t%s %p (%s)\n", //
hostname, getpid(), //
suffix, wantstr, gotstr, //
want, wantstr, //
opstr, got, gotstr);
if (!isempty(fmt)) {
kprintf("\t");
va_start(va, fmt);