Skip to content

Added restriction to profile name length

Currently, there are no restrictions to name length when it comes to choosing a name for a new profile or renaming an existing profile. If file name of the profile file exceeds the limits imposed by the system, a profile is created with the chosen name. However, there is no associated profile file created for the new profile. When the application boots up again, the created profile is not shown due to not being able to load it from a file.

This change implements a restriction on the length of names of profiles. The maximum name length is retrieved by calling pathconf on Linux, FreeBSD, OpenBSD, Solaris and MacOS systems. On Windows, it is done by inspecting the MAX_PATH environment variable. If the user tries to use a name violating the length limits, a warning message is shown similar to the message shown when trying to use a name of another existing profile.

Edited by Theodore Wang

Merge request reports