Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 11 Nov 2016 02:13:40 +0000 (UTC)
From:      Joe Marcus Clarke <marcus@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r425858 - in head/ports-mgmt/portlint: . src
Message-ID:  <201611110213.uAB2De7B062315@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: marcus
Date: Fri Nov 11 02:13:40 2016
New Revision: 425858
URL: https://svnweb.freebsd.org/changeset/ports/425858

Log:
  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

Modified:
  head/ports-mgmt/portlint/Makefile
  head/ports-mgmt/portlint/src/portlint.pl

Modified: head/ports-mgmt/portlint/Makefile
==============================================================================
--- head/ports-mgmt/portlint/Makefile	Fri Nov 11 01:01:38 2016	(r425857)
+++ head/ports-mgmt/portlint/Makefile	Fri Nov 11 02:13:40 2016	(r425858)
@@ -3,6 +3,7 @@
 
 PORTNAME=	portlint
 PORTVERSION=	2.17.5
+PORTREVISION=	1
 CATEGORIES=	ports-mgmt
 MASTER_SITES=	# none
 DISTFILES=	# none

Modified: head/ports-mgmt/portlint/src/portlint.pl
==============================================================================
--- head/ports-mgmt/portlint/src/portlint.pl	Fri Nov 11 01:01:38 2016	(r425857)
+++ head/ports-mgmt/portlint/src/portlint.pl	Fri Nov 11 02:13:40 2016	(r425858)
@@ -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");
 				}
 			}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201611110213.uAB2De7B062315>