Commit 1ac9d7ea authored by terry%netscape.com's avatar terry%netscape.com

Patch by Sam Ziegler <ziegler@mediaguaranty.com> -- do some sanity

checking on the list of column names we're given.
parent 7c36a999
...@@ -23,6 +23,7 @@ puts "Content-type: multipart/x-mixed-replace;boundary=ThisRandomString" ...@@ -23,6 +23,7 @@ puts "Content-type: multipart/x-mixed-replace;boundary=ThisRandomString"
puts "" puts ""
puts "--ThisRandomString" puts "--ThisRandomString"
# The below "if catch" stuff, if uncommented, will trap any error, and # The below "if catch" stuff, if uncommented, will trap any error, and
# mail the error messages to terry. What a hideous, horrible # mail the error messages to terry. What a hideous, horrible
# debugging hack. # debugging hack.
...@@ -155,8 +156,10 @@ select ...@@ -155,8 +156,10 @@ select
foreach c $collist { foreach c $collist {
if {[info exists needquote($c)] } {
append query ", append query ",
\t$key($c)" \t$key($c)"
}
} }
...@@ -238,6 +241,7 @@ Click the <B>Back</B> button and try again." ...@@ -238,6 +241,7 @@ Click the <B>Back</B> button and try again."
} }
if {[info exists FORM(order)]} { if {[info exists FORM(order)]} {
qadd "order by " qadd "order by "
switch -glob $FORM(order) { switch -glob $FORM(order) {
...@@ -267,7 +271,6 @@ if {[info exists FORM(debug)]} { ...@@ -267,7 +271,6 @@ if {[info exists FORM(debug)]} {
puts "<pre>$query</pre>" puts "<pre>$query</pre>"
} }
flush stdout flush stdout
SendSQL $query SendSQL $query
set count 0 set count 0
...@@ -297,6 +300,7 @@ set tablestart "<TABLE CELLSPACING=0 CELLPADDING=2> ...@@ -297,6 +300,7 @@ set tablestart "<TABLE CELLSPACING=0 CELLPADDING=2>
foreach c $collist { foreach c $collist {
if { [info exists needquote($c)] } {
if {$needquote($c)} { if {$needquote($c)} {
append tablestart "<TH WIDTH=100% valigh=left>" append tablestart "<TH WIDTH=100% valigh=left>"
} else { } else {
...@@ -307,6 +311,7 @@ foreach c $collist { ...@@ -307,6 +311,7 @@ foreach c $collist {
} else { } else {
append tablestart $title($c) append tablestart $title($c)
} }
}
} }
append tablestart "\n" append tablestart "\n"
...@@ -366,7 +371,7 @@ while { $p_true } { ...@@ -366,7 +371,7 @@ while { $p_true } {
} }
if {$needquote($c)} { if { [info exists needquote($c)] && $needquote($c)} {
set value [html_quote $value] set value [html_quote $value]
} else { } else {
set value "<nobr>$value</nobr>" set value "<nobr>$value</nobr>"
...@@ -383,7 +388,6 @@ while { $p_true } { ...@@ -383,7 +388,6 @@ while { $p_true } {
} }
} }
} }
puts "" puts ""
puts "--ThisRandomString" puts "--ThisRandomString"
...@@ -398,7 +402,6 @@ if { [info exists buglist] } { ...@@ -398,7 +402,6 @@ if { [info exists buglist] } {
} }
} }
puts "" puts ""
set env(TZ) PST8PDT set env(TZ) PST8PDT
PutHeader "Bug List" "Bug List" PutHeader "Bug List" "Bug List"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment