mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-15 10:02:47 +03:00
vere: don't crash when slogging during replay
We're not guaranteed to have the sog_f callback set when _pier_on_lord_slog gets called, so we should make sure there's a function there before we call it.
This commit is contained in:
parent
a6af035532
commit
1bce077ab4
@ -972,11 +972,21 @@ _pier_on_lord_slog(void* ptr_v, c3_w pri_w, u3_noun tan)
|
||||
u3C.stderr_log_f(tan_c);
|
||||
c3_free(tan_c);
|
||||
|
||||
pir_u->sog_f(pir_u->sop_p, pri_w, tan);
|
||||
if ( 0 != pir_u->sog_f ) {
|
||||
pir_u->sog_f(pir_u->sop_p, pri_w, tan);
|
||||
}
|
||||
else {
|
||||
u3z(tan);
|
||||
}
|
||||
}
|
||||
else {
|
||||
u3_pier_tank(0, pri_w, u3k(tan));
|
||||
pir_u->sog_f(pir_u->sop_p, pri_w, tan);
|
||||
if ( 0 != pir_u->sog_f ) {
|
||||
pir_u->sog_f(pir_u->sop_p, pri_w, tan);
|
||||
}
|
||||
else {
|
||||
u3z(tan);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user