Posted to tcl by ybloc at Sat Jan 20 20:53:51 GMT 2024view raw

  1. ######################################
  2. ### Timer for the mysql connection ###
  3. ######################################
  4. if {[timerexists pre:dbconnection] !=""} { killtimer $dbconnect(dbtimer) }
  5.  
  6. set dbconnect(dbtimer) [timer 1 pre:dbconnection]
  7.  
  8. proc pre:dbconnection {} {
  9. global mysql_ dbconnect
  10. if {[catch {mysqlping $mysql_(handle)}] != 0} {
  11. set mysql_(handle) [mysqlconnect -host $mysql_(host) -user $mysql_(user) -password $mysql_(password) -db $mysql_(database)]
  12. }
  13. if {[set var [timerexists pre:dbconnection]] !="" } { killtimer $var }
  14. set dbconnect(dbtimer) [timer 1 pre:dbconnection]
  15. }
  16. #if {[file exists /usr/lib/mysqltcl-3.02/libmysqltcl3.02.so]} {
  17. # load /usr/lib/mysqltcl-3.02/libmysqltcl3.02.so
  18. #}
  19. ####################################END OF SCRIPT###############################
  20.  
  21. Tcl error in file 'eggdrop.conf':
  22. invalid command name "timerexists"
  23. while executing
  24. "timerexists pre:dbconnection"
  25. (file "scripts/pre.tcl" line 1783)
  26. invoked from within
  27.