pub fn target_list() -> Result<Vec<TargetInfo>> {
    let mut os = memflow_native::build_os(
        &Default::default(),
        None,
        Option::<std::sync::Arc<_>>::None.into(),
    )?;

    let mut out = vec![];

    let callback = &mut |info: ProcessInfo| {
        if is_qemu(&info) {
            if let Some(n) = qemu_arg_opt(info.command_line.split_whitespace(), "-name", "guest") {
                out.push(TargetInfo {
                    name: ReprCString::from(n),
                });
            }
        }

        true
    };

    os.process_info_list_callback(callback.into())?;

    Ok(out)
}
/// Retrieve a list of all currently available Qemu targets.
Retrieve a list of all currently available Qemu targets.
Retrieve a list of all currently available Qemu targets .
pub fn target_list() -> Result<Vec<TargetInfo>> {
    let mut os = memflow_native::build_os(
        &Default::default(),
        None,
        Option::<std::sync::Arc<_>>::None.into(),
    )?;
    let mut out = vec![];
    let callback = &mut |info: ProcessInfo| {
        if is_qemu(&info) {
            if let Some(n) = qemu_arg_opt(info.command_line.split_whitespace(), "-name", "guest") {
                out.push(TargetInfo {
                    name: ReprCString::from(n),
                });
            }
        }
        true
    };
    os.process_info_list_callback(callback.into())?;
    Ok(out)
}
pub fn target_list ( ) -> Result < Vec < TargetInfo > > { let mut os = memflow_native :: build_os ( & Default :: default ( ) , None , Option :: < std :: sync :: Arc < _ > > :: None . into ( ) , ) ? ; let mut out = vec ! [ ] ; let callback = & mut | info : ProcessInfo | { if is_qemu ( & info ) { if let Some ( n ) = qemu_arg_opt ( info . command_line . split_whitespace ( ) , " " , " " ) { out . push ( TargetInfo { name : ReprCString :: from ( n ) , } ) ; } } true } ; os . process_info_list_callback ( callback . into ( ) ) ? ; Ok ( out ) }
Retrieve a list of all currently available Qemu targets.
Retrieve a list of all currently available Qemu targets .