Broken debugger (aimed) and bug which corrupt memory, crash fire

Hello

This time I lose 1 day :frowning:
Please first check my post about libz and edit about NSMutableData problem. First I think that problem is with NSMutableData but deep test show that is not true.

*** FXGen import problem

Attached sample project to reproduce:

NSMutableData.zip (118.1 KB)

I’m wish to have global variables so I create static class to store data accessible in every class. This cause serious problems like destroyed debugger and depend of class (static or not), broken returned NSMutableData buffer. In my project I get broken buffer, not matter if class is static or not. I’m sure this is response too for my post about broken debugger. *** Debugger problem

Make break point on: NSLog("%X", byt); to trace step by step broken data in output buffer

Find in function.cs code marked with:

/ this one produce debugger errors but output is correct. NSLog is not reachable*

and

/ this one produce debugger error and broken output data. NSLog is not reachable /

Both influence debugger but one buffer data (depend of how big project it, it will influence both)

I also try to use static struct but in my project it produce “Error 8 (E0) Internal error: LPUSH->U78” for every place in code which trying to access truct.

I have tested this one Fire and fire totally crash on 3 debugger steps on NSLog("%X", byt);

Have no idea for workaround :confused:

[EDIT]

NSLog is not reachable note is clear now for me. Static classes need to be initialized with static constructor first, otherwise all values are null. Anyway this do not fix main problem.

b.r.

Can you send me your libz too?

Ahh yes sure.
But problem is not related with libz. You can remove (I forgot) it from references and project will run. I add as many references as I use in my project to spot the problem, so there You will see unused one.

libz.zip (65.4 KB)

b.r.