1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2024-09-13 07:13:00 +03:00

Merge pull request #1782 from metalefty/adjust-version-string

Cedar: Trim contiguous whitespaces in version string
This commit is contained in:
Ilya Shipitsin 2023-03-12 08:32:55 +01:00 committed by GitHub
commit e6123d36a0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1564,11 +1564,14 @@ CEDAR *NewCedar(X *server_x, K *server_k)
#endif // ALPHA_VERSION
ToStr(tmp2, c->Beta);
Format(tmp2, sizeof(tmp2), " %s %s ", beta_str, tmp2);
Format(tmp, sizeof(tmp), "Version %u.%02u Build %u %s %s (%s)",
Format(tmp, sizeof(tmp),
"Version %u.%02u Build %u"
"%s" // Alpha, Beta, Release Candidate or nothing
"(%s)", // Language
CEDAR_VERSION_MAJOR, CEDAR_VERSION_MINOR, CEDAR_VERSION_BUILD,
c->Beta == 0 ? "" : beta_str,
c->Beta == 0 ? "" : tmp2,
c->Beta == 0 ? " " : tmp2,
_SS("LANGSTR"));
Trim(tmp);