]> git.pld-linux.org Git - packages/rpm-build-tools.git/commitdiff
- more debug, don't hang on empty hrefs
authorJakub Bogusz <qboosh@pld-linux.org>
Fri, 9 Apr 2004 12:53:44 +0000 (12:53 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    pldnotify.awk -> 1.43

pldnotify.awk

index 637bb141597d8d8d500910c49e5530ebd58fddb0..ecc71bbb8464b3f4903f0e28fa87e5212d1ce2fc 100644 (file)
@@ -169,27 +169,30 @@ function get_links(url,   errno,link,oneline,retval,odp,tmpfile) {
                                        if (DEBUG) print "Ramka->: " newurl
                                }
                                retval=(retval " " get_links(newurl))
-                       } else if (tolower(odp) ~ /href=[ \t]*"[^"]+"/) {
+                       } else if (tolower(odp) ~ /href=[ \t]*"[^"]*"/) {
                                sub(/[hH][rR][eE][fF]=[ \t]*"/,"href=\"",odp)
-                               match(odp,/href="[^"]+"/)
+                               match(odp,/href="[^"]*"/)
                                link=substr(odp,RSTART,RLENGTH)
                                odp=substr(odp,1,RSTART) substr(odp,RSTART+RLENGTH)
                                link=substr(link,7,length(link)-7)
                                retval=(retval " " link)
-                       } else if (tolower(odp) ~ /href=[ \t]*'[^']+'/) {
+                               if (DEBUG) print "href(\"\"): " link
+                       } else if (tolower(odp) ~ /href=[ \t]*'[^']*'/) {
                                sub(/[hH][rR][eE][fF]=[ \t]*'/,"href='",odp)
-                               match(odp,/href='[^']+'/)
+                               match(odp,/href='[^']*'/)
                                link=substr(odp,RSTART,RLENGTH)
                                odp=substr(odp,1,RSTART) substr(odp,RSTART+RLENGTH)
                                link=substr(link,7,length(link)-7)
                                retval=(retval " " link)
-                       } else if (tolower(odp) ~ /href=[ \t]*[^ \t>]+/) {
+                               if (DEBUG) print "href(''): " link
+                       } else if (tolower(odp) ~ /href=[ \t]*[^ \t>]*/) {
                                sub(/[hH][rR][eE][fF]=[ \t]*/,"href=",odp)
-                               match(odp,/href=[^ \t>]+/)
+                               match(odp,/href=[^ \t>]*/)
                                link=substr(odp,RSTART,RLENGTH)
                                odp=substr(odp,1,RSTART) substr(odp,RSTART+RLENGTH)
                                link=substr(link,6,length(link)-5)
                                retval=(retval " " link)
+                               if (DEBUG) print "href(): " link
                        } else {
                                retval=(retval " INTERNAL_ERROR")
                                break
This page took 0.047629 seconds and 4 git commands to generate.