I see, that makes perfect sense :-).. So I just might need to flip
around my "if" to get it to work.
-----Original Message-----
From: Marian Dumitru [mailto:marian.dumitru@voice-sistem.ro]
Sent: Thursday, April 21, 2005 5:10 PM
To: Matt Schulte
Cc: serusers(a)lists.iptel.org
Subject: Re: [Serusers] if routeXX fails..
Hi Matt,
Basically you can do that, but be very careful since the return code of
a route is the return code of the *last* command executed inside the
route - and break always returns true!
Best regards,
Marian
Matt Schulte wrote:
Is it possible to do this? or is it bad practice,
I'm assuming the
"extra" route would have to return an error code to show a
nonpositive? I coulda swore I got this to work awhile back.
if (!route(6)) {
xlog("L_INFO", "NOTICE: blah <%ru> sending 404\n");
sl_send_reply("404", "Not Found");
break;
} else {
# Else route6 ran another route and break
break;
}
--
Voice System
http://www.voice-system.ro