Trim the He-3 response before splitting to remove empty list elements

Damn you, TCL ...
This commit is contained in:
Douglas Clowes
2014-11-06 11:13:32 +11:00
parent 4620c7b079
commit 1f6d28637d
2 changed files with 2 additions and 2 deletions

View File

@ -43,7 +43,7 @@ driver he3_polanal = {
%%} %%}
code rdValue = {%% code rdValue = {%%
set dlist [split ${data}] set dlist [split [string trim ${data}]]
if {[llength ${dlist}] < 2} { if {[llength ${dlist}] < 2} {
sct geterror "Syntax Error: '${data}'" sct geterror "Syntax Error: '${data}'"
error "[sct geterror]" error "[sct geterror]"

View File

@ -108,7 +108,7 @@ proc ::scobj::he3_polanal::rdValue {tc_root} {
error "[sct geterror]" error "[sct geterror]"
} }
# rdValue hook code starts # rdValue hook code starts
set dlist [split ${data}] set dlist [split [string trim ${data}]]
if {[llength ${dlist}] < 2} { if {[llength ${dlist}] < 2} {
sct geterror "Syntax Error: '${data}'" sct geterror "Syntax Error: '${data}'"
error "[sct geterror]" error "[sct geterror]"