<div dir="ltr">I am debugging an issue (x86_64 Linux platform) which I have in FPC 3.0 which I didn't have in 2.6.4. It is a complex project with a lot of threading, custom memory management, etc., so it's not something I can easily boil down at the moment. Generally it manifests itself in memory corruption.<div><br></div><div>As I'm eliminating possibilities, I see often my crashes happen when various ansistring conversions/setlengths/etc. are happening. As I read <a href="http://wiki.freepascal.org/FPC_Unicode_support">http://wiki.freepascal.org/FPC_Unicode_support</a> I can see that there were a lot of changes that went into unicode support in 3.0, particularly with making ansistrings codepage-aware.</div><div><br></div><div>I understand that if I'm doing things "right" with ansistrings, everything will work correctly and transparently. However, I worry that there may be places in our code where we are doing bad things with ansistrings that may be the root of my problem.</div><div><br></div><div>To identify whether or not this is really the case, is there some way I can use the  FPC compiler but have the behavior of ansistrings act like it did in fpc 2.6.4? For example, can I do:</div><div><br></div><div>SetMultiByteConversionCodePage(CP_NONE);</div><div><br></div><div>or is there some kind of compiler flag I can set in my project? Or even if I have to rebuild the compiler itself, can I have the old 2.6.4 ansistring behavior in FPC 3.0?</div><div><br></div><div>Even if I had to change all of my ansistring declarations to rawbytestring I could do that, although that would require me to touch more code and I'd prefer to find some sort of flip-a-switch way to do it.</div><div><br></div><div>Thanks for your input,</div><div><div><br></div><div>-SG</div><div><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr">--<br>Seth Grover<br><br>
Be kind to all of your neighbors<br>
Because they're just like you.<br>
And you're nothing special<br>
Unless they are too.<br></div></div></div></div></div>
</div></div></div>