Fix reversed version comparison
authorJamie Cameron <jcameron@webmin.com>
Wed, 12 Jan 2011 23:15:52 +0000 (15:15 -0800)
committerJamie Cameron <jcameron@webmin.com>
Wed, 12 Jan 2011 23:15:52 +0000 (15:15 -0800)
software/software-lib.pl

index 949712a..e340086 100755 (executable)
@@ -235,7 +235,7 @@ for(my $i=0; $i<@sp1 || $i<@sp2; $i++) {
                # Numeric compared to non-numeric - numeric is always higher
                $comp = 1;
                }
-       elsif ($v1 =~ /^\d+$/ && $v2 !~ /^\d+$/) {
+       elsif ($v1 !~ /^\d+$/ && $v2 =~ /^\d+$/) {
                # Non-numeric compared to numeric - numeric is always higher
                $comp = -1;
                }