The script which adds information to the database is this:
putlog "NickHost: Join check on $nick: Adding new host $host"
set filewrite [open $nickdb a]
puts $filewrite "$nick $host"
close $filewrite
$nick being the nick of the person who just joined the channel, etc
Then, a user submits a request to view certain information, and this part of the script is used:
putnotc $nick "Nicks in the database matching the host: \002$whoishost\002"
set showopen [open $nickdb r]
set show [read $showopen]
close $showopen
foreach listnick [split $show \n] {
if { [lindex $listnick 1] == $whoishost } {
putnotc $nick "\002ø\002 [lindex $listnick 0]"
}
}
This just lists the nicks matching a certain host which are in the file.
It was working fine. Now, when a user with { in there nick joined and was registered by the bot, whenever anyone requests information, the script *can* still work, although sometimes it does, but the error message
<InfinitY> [15:30] Tcl error [savehost-whois]: unmatched open brace in list
Simon