zlog: Ensure log file is flushed (#28923)

Closes #ISSUE

Release Notes:

- N/A *or* Added/Fixed/Improved ...
This commit is contained in:
Ben Kunkle 2025-04-16 19:30:23 -04:00 committed by GitHub
parent 9ea8a9a1d3
commit 63b4b60b79
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 14 additions and 2 deletions

View file

@ -130,6 +130,7 @@ pub fn init_panic_hook(
if let Some(panic_data_json) = serde_json::to_string_pretty(&panic_data).log_err() {
log::error!("{}", panic_data_json);
}
zlog::flush();
if !is_pty {
if let Some(panic_data_json) = serde_json::to_string(&panic_data).log_err() {