Menu

#542 Larger default max string length

3.0 Series
open
nobody
None
5
2023-06-20
2017-07-09
No

Can we please make the large-strings build (max string length 8192) the default build for NSIS in future releases?

This would make it possible for package maintainers for Linux and macOS to make that the standard they ship without deviating from the NSIS defaults.

Discussion

  • Mike Pilgrem

    Mike Pilgrem - 2023-06-19

    I support this request. GitHub hosted runners for Windows currently include NSIS 3.08, but it is the default build with the 1024 byte limit. There is a reluctance for the runners to include a NSIS build that is other than 'default' (and, also, is not packaged as an executable), see: https://github.com/actions/runner-images/issues/7740 . The NSIS wiki and elsewhere (eg https://hackage.haskell.org/package/nsis-0.3.3/docs/Development-NSIS-Plugins-EnvVarUpdate.html) warn that the 1024 byte limit can result in installers that corrupt users PATH environment variable. I have experience of a user being affected adversely by such an installer.

     

    Last edit: Mike Pilgrem 2023-06-19
  • Jason

    Jason - 2023-06-20

    Regarding environment variables, I wrote a plugin on the wiki that handles environment variables and doesn't rely on the string length (edit: only the path you pass in from the script is limited to the string limit, but I doubt a single path will be more than 1024 characters anyway; windows paths have a base limit of 260, but with special syntax can be longer).

    https://nsis.sourceforge.io/EnVar_plug-in.

     

    Last edit: Jason 2023-06-20
  • Anders

    Anders - 2023-06-20

    8192 is still less than the %path% limit, it just makes the problem less likely. Using the plug-in Jason linked to is the recommended solution.

     

Log in to post a comment.

MongoDB Logo MongoDB