@@ -461,25 +461,24 @@ impl Server {
461461 } ;
462462
463463 let mut writer =
464- minidump_writer:: minidump_writer:: MinidumpWriter :: new( crash_context. inner. pid, crash_context. inner. tid) ;
464+ minidump_writer:: minidump_writer:: MinidumpWriterConfig :: new( crash_context. inner. pid, crash_context. inner. tid) ;
465465
466466 writer. set_crash_context( crash_context) ;
467+ let result = writer. write( & mut minidump_file) ;
467468 } else if #[ cfg( target_os = "windows" ) ] {
468469 // SAFETY: Unfortunately this is a bit dangerous since we are relying on the crashing process
469470 // to still be alive and still have the interior pointers in the crash context still at the
470471 // same location in memory, unfortunately it's a bit hard to communicate this through so
471472 // many layers, so really, we are falling back on Windows to actually correctly handle
472473 // if the interior pointers have become invalid which it should? do ok with
473474 let result =
474- minidump_writer:: minidump_writer:: MinidumpWriter :: dump_crash_context( crash_context, None , & mut minidump_file) ;
475+ minidump_writer:: minidump_writer:: MinidumpWriter :: dump_crash_context( & crash_context, None , & mut minidump_file) ;
475476 } else if #[ cfg( target_os = "macos" ) ] {
476477 let mut writer = minidump_writer:: minidump_writer:: MinidumpWriter :: with_crash_context( crash_context) ;
478+ let result = writer. dump( & mut minidump_file) ;
477479 }
478480 }
479481
480- #[ cfg( not( target_os = "windows" ) ) ]
481- let result = writer. dump ( & mut minidump_file) ;
482-
483482 // Notify the user handler about the minidump, even if we failed to write it
484483 Ok ( handler. on_minidump_created (
485484 result
0 commit comments