Mercurial > hg > egg-tcls
comparison fetch_feeds.tcl @ 424:825cac46b1cb
Cosmetic / stray trailing whitespace cleanup.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sun, 08 Jan 2017 03:55:55 +0200 |
parents | 44c9128097cd |
children | e5810c52d376 |
comparison
equal
deleted
inserted
replaced
423:44c9128097cd | 424:825cac46b1cb |
---|---|
108 puts "Error getting $datauri: $uerrmsg" | 108 puts "Error getting $datauri: $uerrmsg" |
109 return 1 | 109 return 1 |
110 } | 110 } |
111 set upage [::http::data $utoken] | 111 set upage [::http::data $utoken] |
112 ::http::cleanup $utoken | 112 ::http::cleanup $utoken |
113 | 113 |
114 set umatches [regexp -all -nocase -inline -- "<item>.\*\?<title><..CDATA.(.\*\?)\\\]\\\]></title>.\*\?<link>(http.\*\?)</link>.\*\?</item>" $upage] | 114 set umatches [regexp -all -nocase -inline -- "<item>.\*\?<title><..CDATA.(.\*\?)\\\]\\\]></title>.\*\?<link>(http.\*\?)</link>.\*\?</item>" $upage] |
115 set nmatches [llength $umatches] | 115 set nmatches [llength $umatches] |
116 for {set n 0} {$n < $nmatches} {incr n 3} { | 116 for {set n 0} {$n < $nmatches} {incr n 3} { |
117 add_entry $dataname $dataprefix [lindex $umatches [expr $n+2]] [lindex $umatches [expr $n+1]] | 117 add_entry $dataname $dataprefix [lindex $umatches [expr $n+2]] [lindex $umatches [expr $n+1]] |
118 } | 118 } |
119 | 119 |
120 if {$nmatches == 0} { | 120 if {$nmatches == 0} { |
121 set umatches [regexp -all -nocase -inline -- "<item>.\*\?<title>(.\*\?)</title>.\*\?<link>(http.\*\?)</link>.\*\?</item>" $upage] | 121 set umatches [regexp -all -nocase -inline -- "<item>.\*\?<title>(.\*\?)</title>.\*\?<link>(http.\*\?)</link>.\*\?</item>" $upage] |
122 set nmatches [llength $umatches] | 122 set nmatches [llength $umatches] |
123 for {set n 0} {$n < $nmatches} {incr n 3} { | 123 for {set n 0} {$n < $nmatches} {incr n 3} { |
124 add_entry $dataname $dataprefix [lindex $umatches [expr $n+2]] [lindex $umatches [expr $n+1]] | 124 add_entry $dataname $dataprefix [lindex $umatches [expr $n+2]] [lindex $umatches [expr $n+1]] |