Boost C++ Libraries: Ticket #5300: temp_directory_path failure on Windows with path length > 130 char https://svn.boost.org/trac10/ticket/5300 <p> The <a class="missing wiki">GetTempPath</a> API (which temp_directory_path uses internally) will not behave as expected if the path to the temp dir is longer than 130 characters. </p> <p> A workaround is to first try to use <a class="missing wiki">GetEnvironmentVariable</a> on "TMP" and "TEMP", then fall back on <a class="missing wiki">GetTempPath</a>. </p> <p> No patch provided because unfortunately I don't have access to my tools at the moment, but it should be a relatively trivial fix. </p> <p> Thanks in advance. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/5300 Trac 1.4.3 Joshua Boyce <raptorfactor@…> Sun, 13 Mar 2011 15:49:57 GMT <link>https://svn.boost.org/trac10/ticket/5300#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/5300#comment:1</guid> <description> <p> More information on the problem available here: <a class="ext-link" href="https://blogs.msdn.com/b/larryosterman/archive/2010/10/19/because-if-you-do_2c00_-stuff-doesn_2700_t-work-the-way-you-intended_2e00_.aspx"><span class="icon">​</span>https://blogs.msdn.com/b/larryosterman/archive/2010/10/19/because-if-you-do_2c00_-stuff-doesn_2700_t-work-the-way-you-intended_2e00_.aspx</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Beman Dawes</dc:creator> <pubDate>Tue, 03 Feb 2015 17:03:34 GMT</pubDate> <title>status, milestone changed; resolution set https://svn.boost.org/trac10/ticket/5300#comment:2 https://svn.boost.org/trac10/ticket/5300#comment:2 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> <li><strong>milestone</strong> <span class="trac-field-old">To Be Determined</span> → <span class="trac-field-new">Boost 1.58.0</span> </li> </ul> <p> Rewrite Windows implementation of temp_directory_path() to (1) avoid <a class="missing wiki">GetTempPath</a>() to fix ticket and (2) provide a more sensible sequence of directories than provided by <a class="missing wiki">GetTempPath</a>(), per boost list discussion "[filesystem] temp_directory_path() behavior on Windows". </p> <p> Sorry to take so long to get to this. </p> <p> Thanks, </p> <p> --Beman </p> Ticket