1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2026-01-13 12:30:55 +00:00
openmw/apps/esmtool
AnyOldName3 16efa6e5b5 Support long paths on Windows
Apparently we'd never bothered opting in, despite nearly everything in all out apps being entirely compatible and designed with long paths in mind.

GetModuleFileNameW is a bit awkward as it's just about the only Win32 function that returns the minimum of the buffer size and the string size - nearly everything else returns the full size even if it won't fit, so you can pass it a null pointer and a size of zero, and it'll tell you how much space you need to allocate.

I pretty much just copied the mostly-working long-path-friendly call site in the crash catcher to windowspath.cpp, but I also noticed that if the function failed and returned zero, the original implementation would loop forever, so I fixed that.

There was some code that could be ditched from the catch monitor as \\?\ is a prefix you can use to opt into long paths for a single API call instead of using the manifest to set it everywhere.
2026-01-07 15:12:22 +00:00
..
.gitignore Moved esmtool to apps/ 2010-07-21 13:52:28 +02:00
arguments.hpp Apply clang-format to code base 2022-09-22 21:35:26 +03:00
CMakeLists.txt Support long paths on Windows 2026-01-07 15:12:22 +00:00
esmtool.cpp Print angles in degrees in esmtool 2025-12-21 15:21:22 +03:00
labels.cpp Use std::format in esmtool 2025-08-10 12:03:34 +02:00
labels.hpp Implement auto calculated potion values 2024-03-02 12:45:48 +01:00
record.cpp Improve esmtool destination position/rotation formatting 2025-12-27 01:13:20 +03:00
record.hpp Replace some empty constructors and destructors with default 2023-05-29 13:37:19 +02:00
tes4.cpp Add and fix -Wshadow 2025-08-18 21:09:06 +02:00
tes4.hpp Support TES4 in esmtool dump 2022-04-25 17:35:26 +02:00