Ticket #32589: patch-base-src-port1.0-portlivecheck.tcl.diff

File patch-base-src-port1.0-portlivecheck.tcl.diff, 1.6 KB (added by pixilla (Bradley Giesbrecht), 13 years ago)
  • port1.0/portlivecheck.tcl

    old new  
    11# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
    22# portlivecheck.tcl
    33#
    4 # $Id: portlivecheck.tcl 88031 2011-12-16 22:44:18Z raimue@macports.org $
     4# $Id: portlivecheck.tcl 83525 2011-09-04 11:59:25Z cal@macports.org $
    55#
    66# Copyright (c) 2007-2011 The MacPorts Project
    77# Copyright (c) 2005-2007 Paul Guyot <pguyot@kallisys.net>,
     
    169169                    set updated_version 0
    170170                    set foundmatch 0
    171171                    while {[gets $chan line] >= 0} {
    172                         set matches [regexp -all -inline $the_re $line]
    173                         foreach {matched upver} $matches {
     172                        set lastoff 0
     173                        while {[regexp -start $lastoff -indices $the_re $line offsets]} {
     174                            regexp -start $lastoff $the_re $line matched upver
    174175                            set foundmatch 1
    175176                            if {$updated_version == 0 || [vercmp $upver $updated_version] > 0} {
    176177                                set updated_version $upver
    177178                            }
    178179                            ui_debug "The regex matched \"$matched\", extracted \"$upver\""
     180                            lassign $offsets firstoff lastoff
    179181                        }
    180182                    }
    181183                    if {$foundmatch == 1} {