diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2016-11-11 02:13:40 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2016-11-11 02:13:40 +0000 |
commit | 7ff2ece9967bd593ca345a5860426aa002c12fb8 (patch) | |
tree | e3e048b60b5e5c14533ea3279f41fa969df2854f /ports-mgmt/portlint/src | |
parent | sysutils/consul: update 0.7.1 (diff) |
Correct a typo with TIMESTAMP handling. While here, don't use a pure magic number
for the 30 days worth of seconds.
PR: 212091
Submitted by: jrm
Notes
Notes:
svn path=/head/; revision=425858
Diffstat (limited to 'ports-mgmt/portlint/src')
-rw-r--r-- | ports-mgmt/portlint/src/portlint.pl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ports-mgmt/portlint/src/portlint.pl b/ports-mgmt/portlint/src/portlint.pl index 97c4bce59844..f48c996d09df 100644 --- a/ports-mgmt/portlint/src/portlint.pl +++ b/ports-mgmt/portlint/src/portlint.pl @@ -15,7 +15,7 @@ # was removed. # # $FreeBSD$ -# $MCom: portlint/portlint.pl,v 1.396 2016/11/09 00:33:57 jclarke Exp $ +# $MCom: portlint/portlint.pl,v 1.397 2016/11/11 02:12:15 jclarke Exp $ # use strict; @@ -395,10 +395,10 @@ sub checkdistinfo { } if (/^TIMESTAMP\s+=\s+(\d+)$/) { my $now = time; - if ($_ > $now) { + if ($1 > $now) { &perror("FATAL", $file, $., "TIMESTAMP is in the future"); } else { - if ($now - $_ > 2592000) { + if ($now - $1 > (30 * 60 * 60 * 24)) { &perror("WARN", $file, $., "TIMESTAMP is over 30 days old"); } } |