Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"The system detected an invalid pointer address in attempting to use a pointer argument in a call." #1

Closed
Colecf opened this issue Aug 16, 2023 · 1 comment · Fixed by #4

Comments

@Colecf
Copy link

Colecf commented Aug 16, 2023

Hi, I can't get textractor-websocket to work. After 3 lines of text, there's a windows popup that looks like this:
image

I'm attempting to use the 32-bit extension with the 32-bit textractor, and obviously a 32-bit game.

Running Textractor from the command line with RUST_BACKTRACE=full and a debug build of textractor-websocket gives:

>usage: Textractor [-p{process ID|"process name"}]...
example: Textractor -p4466 -p"My Game.exe" tries to inject processes with ID 4466 or with name My Game.exe
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: WS Error <Io(Os { code: 10014, kind: Uncategorized, message: "The system detected an invalid pointer address in attempting to use a pointer argument in a call." })>', src\textractor_ws.rs:16:38
stack backtrace:
   0: 0x64b8703a - OnNewSentence
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: WS Error <Queue(Disconnected)>', src\textractor_ws.rs:19:35
stack backtrace:
   0: 0x64b8703a - OnNewSentence
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendTimeoutError(..)"', src\textractor_ws.rs:31:42
stack backtrace:
   0: 0x64b8703a - OnNewSentence

So it appears the first line of text causes me.listen(ADDRESS).unwrap() to crash, the second causes broacaster.broadcast(msg).unwrap(); to crash. Those are both in background threads so it's not visible to the user yet. Then the third line causes sender.send_timeout(s, SEND_TIMEOUT).unwrap(); to crash and produce a user-visible error.

I tried changing ADDRESS to use localhost and 127.0.0.1 instead of 0.0.0.0, but those also error out. I also see this error with the prebuilt from the github release.

I've noticed then when running the demo app with rustup run stable-i686-pc-windows-msvc cargo run, I see the same error as in textractor. But if I run cargo update, rebuild and retry, the demo app works perfectly, but the extension still gets the same error.

I couldn't figure out how to print to stdout/stderr, and thus I couldn't figure out how to turn on logging to try to debug it more.

At this point I'm wondering if it's a bug in ws. I'm also curious how this extension works for most people, idk what my setup might be doing differently.

@Colecf
Copy link
Author

Colecf commented Aug 17, 2023

Ok, I figured out my issue. I wasn't updating the extension in Textractor when testing, I didn't realize you had to delete it from Textractor's folder instead of just removing it in the UI, sorry about that.

The binary from the releases page works fine, but a local build gets this error unless I run cargo update first. Local builds also work in Textractor after the update now that I know how to properly update the extension.

So I guess the only request from this issue would be running cargo update.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant