vmemory icon indicating copy to clipboard operation
vmemory copied to clipboard

Can't write memory on MacOS.

Open chenyanchen opened this issue 3 years ago • 1 comments

Hope you are well.

This issues occurred in my demo application.

MacOS version: 12.2.1 (21D62)

Rust version:

$ rustc --version   
rustc 1.58.1 (db9d1b20b 2022-01-20)

Read memory is work, write memory panicked:

thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: 1', /Users/miasto/.cargo/registry/src/github.com-1ecc6299db9ec823/vmemory-0.1.8/src/memory_darwin.rs:235:7
stack backtrace:
   0: rust_begin_unwind
             at /rustc/db9d1b20bba1968c1ec1fc49616d4742c1725b4b/library/std/src/panicking.rs:498:5
   1: core::panicking::panic_fmt
             at /rustc/db9d1b20bba1968c1ec1fc49616d4742c1725b4b/library/core/src/panicking.rs:107:14
   2: core::result::unwrap_failed
             at /rustc/db9d1b20bba1968c1ec1fc49616d4742c1725b4b/library/core/src/result.rs:1613:5
   3: core::result::Result<T,E>::unwrap
             at /rustc/db9d1b20bba1968c1ec1fc49616d4742c1725b4b/library/core/src/result.rs:1295:23
   4: vmemory::memory_darwin::sub_alloc
             at /Users/miasto/.cargo/registry/src/github.com-1ecc6299db9ec823/vmemory-0.1.8/src/memory_darwin.rs:230:5
   5: vmemory::memory_darwin::write_memory
             at /Users/miasto/.cargo/registry/src/github.com-1ecc6299db9ec823/vmemory-0.1.8/src/memory_darwin.rs:53:26
   6: vmemory::ProcessMemory::write_memory
             at /Users/miasto/.cargo/registry/src/github.com-1ecc6299db9ec823/vmemory-0.1.8/src/lib.rs:461:13
   7: hello::main
             at ./src/main.rs:20:5
   8: core::ops::function::FnOnce::call_once
             at /rustc/db9d1b20bba1968c1ec1fc49616d4742c1725b4b/library/core/src/ops/function.rs:227:5

chenyanchen avatar Feb 13 '22 05:02 chenyanchen

And when I exec once write, the target process will be 'Not Responding'.

chenyanchen avatar Feb 13 '22 05:02 chenyanchen