svn commit: r447981 - in head/ports-mgmt/portlint: . src

Mathieu Arnold mat at FreeBSD.org
Thu Dec 7 12:07:57 UTC 2017


Le 07/12/2017 à 13:04, Pietro Cerutti a écrit :
> On Dec  7 17 06:22, Joe Marcus Clarke wrote:
>> On 12/7/17 03:13, Pietro Cerutti wrote:
>>> On Dec  7 17 08:10, Pietro Cerutti wrote:
>>>> On Dec  7 17 08:04, Pietro Cerutti wrote:
>>>>> On Aug 15 17 12:43, Joe Marcus Clarke wrote:
>>>>>> Author: marcus
>>>>>> Date: Tue Aug 15 12:43:14 2017
>>>>>> New Revision: 447981
>>>>>> URL: https://svnweb.freebsd.org/changeset/ports/447981
>>>>>>
>>>>>> Log:
>>>>>>   Update to 2.17.12.
>>>>>> @@ -3400,6 +3437,11 @@ sub abspathname {
>>>>>>  
>>>>>>  			if ($pre =~ /MASTER_SITE_SUBDIR/) {
>>>>>>  				# MASTER_SITE_SUBDIR lines are ok.
>>>>>> +				$i = '';
>>>>>> +			}
>>>>>> +			if ($s =~ /\$\{[^}]*?$i/) {
>>>>>> +				# If we're inside a make variable, we probably do not have
>>>>>> +				# an absolute path.
>>>>>>  				$i = '';
>>>>>>  			}
>>>>>>  		}
>>>>>>
>>>>> Unmatched ) in regex; marked by <-- HERE in m/\$\{[^}]*?/dev/null 2>&1 ) 
>>>>> <-- HERE / at /usr/local/bin/portlint line 3443.
>>>>>
>>>>> I think the ? doesn't belong there.
>>>> No, my analysis was wrong. It's about the contents of the $i variable. 
>>>> Here's why. You can reproduce by portlint -AC in net-im/openfire.
>>>>
>>>> i is /var/log/openfire
>>>> WARN: Makefile: possible use of absolute pathname "/var/log/openfire".
>>>>
>>>> i is /var/db/openfire
>>>> WARN: Makefile: possible use of absolute pathname "/var/db/openfire".
>>>>
>>>> i is /dev/null 2>&1 )
>>>> Unmatched ) in regex; marked by <-- HERE in m/\$\{[^}]*?/dev/null 2>&1 ) 
>>>> <-- HERE / at /usr/local/bin/portlint line 3444.
>>> Surrounding $i with \Q and \E in the regex solves the problem.
>>>
>>>
>> Thanks.  I'll commit a quick fix ahead of the next release.
> Thanks. I still don't understand why you have both * and ? as 
> quantifiers, though.


perlre(1):

           *?        Match 0 or more times, not greedily


-- 
Mathieu Arnold


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 949 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/svn-ports-head/attachments/20171207/c783000a/attachment.sig>


More information about the svn-ports-head mailing list