Co, the if 1 statement is always true. It's replicating the format of my original script, but you're right... it's not necessary for execution. Here's a more compact version which gives the same error:

code:
do
gosub "subscript"
until 1 = 1
exit 0
:subscript
exit 1
return