Subj : This crashes sbbs horribly
To   : Digital Man
From : elm
Date : Thu Nov 03 2011 06:25 am

I am building off the example code for the MAIL_SEND function that is located
at http://www.synchro.net/docs/baja.html#Logic/Control%20Flow%20Functions.

What I want to do is abort the mail send request if enter is pressed at the
"Send mail to who? " prompt.  By default, using the example code, if you press
enter you will start to cycle through all the users.

So I thought I would check for a string length of zero and then if false,
continue on to the MAIL_SEND function and if true, abort.  ...but this does not
work.  What I have added crashes sbbs when the mail_send function is called.  I
do enter a correct username at the "Send mail to who? " prompt.

cmdkey S
       cls
       print "Send mail to who? "
       str name
       int namelength
       getname name 25
       strlen namelength name
       compare namelength 0
       if_false
              mail_send
       else
              print "Send aborted.\n"
              pause
              end_if
       end_cmd

echto
bbs.echto.net

---
� Synchronet � -=-= echto bbs =-=-