I just noticed

With a document that does not have the SC_DOCUMENTOPTION_TEXT_LARGE option set, allocating more than 2G (calling SCI_ALLOCATE or similar) will now fail with SC_STATUS_FAILURE.

in 5.4.1 release notes. I'm not sure how geany behaves for large files and whether we should set this flag or not.

It won't be as easy as setting a flag; for eample, you would need SCI_GETTEXTRANGEFULL here:

https://github.com/geany/geany/blob/7a017c764038bcdfcb99db7365c3196fd8aebdbf/src/sciwrappers.c#L1145

And then every plugin has to start using the 64-bit character range APIs to safely handle >2GiB files on Windows, because on that platform the legacy Sci_CharacterRange struct can only hold 32-bit positions (sizeof(long) == 4).

When Notepad++ decided to support huge files the ABI breakage was a total clusterf**k.


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <geany/geany/pull/4168/c2558294031@github.com>