string-util: do not accept ',' in version strings
Allowing this apparently has been cargo-culted from my initial sysupdate PR, but Claude and me could not find a single other software package that uses "," as a character within version strings. Hence, let's remove this, even though this is a compat breakage of a kind, in the hope nobody notices. We can easily restore this if this later shows to be an issue for people.
This commit is contained in:
@@ -1469,8 +1469,8 @@ bool version_is_valid(const char *s) {
|
||||
if (!filename_part_is_valid(s))
|
||||
return false;
|
||||
|
||||
/* This is a superset of the characters used by semver. We additionally allow "," and "_". */
|
||||
if (!in_charset(s, ALPHANUMERICAL ".,_-+"))
|
||||
/* This is a superset of the characters used by semver. We additionally allow "_". */
|
||||
if (!in_charset(s, ALPHANUMERICAL "._-+"))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user