tor: use string comparison to check min supported version
The current method would not allow version strings like 0.4.0.5 since it would check every number of the version string individually.
This commit is contained in:
2 files changed
+18
-14
No files matched your search
@@ -28,6 +28,10 @@ func TestParseTorVersion(t *testing.T) {
|
||||
version: "0.4.3.6",
|
||||
valid: true,
|
||||
},
|
||||
{
|
||||
version: "0.4.0.5",
|
||||
valid: true,
|
||||
},
|
||||
{
|
||||
version: "1.3.3.6",
|
||||
valid: true,
|
||||
@@ -56,6 +60,10 @@ func TestParseTorVersion(t *testing.T) {
|
||||
version: "0.1.3.6",
|
||||
valid: false,
|
||||
},
|
||||
{
|
||||
version: "0.0.6.3",
|
||||
valid: false,
|
||||
},
|
||||
}
|
||||
|
||||
for i, test := range tests {
|
||||
|
||||
Reference in new issue
Block a user