На Fri, 06 Jan 2012 09:38:42 +0100
Daniel-Constantin Mierla <mico...@gmail.com> записано:

> Hello,
> 
> do you have maxfwd module loaded in kamailio.cfg? With it all worked 
> fine for me.

Yes I have.

> There was a missing check if the module was not loaded that could caused 
> the crash, I added the safety check for it and kamailio doesn't start 
> anymore if a registered module to Lua API is not loaded in kamailio.cfg.

Please see config files attached.

Attachment: kamailio.cfg
Description: Binary data

-- SIP request routing
function route_request(name)
	sr.dbg("routing SIP request from Lua [" .. name .. "]\n")

	-- initial checks of SIP request
	if sr.maxfwd.process_maxfwd(10) < 0 then
		sr.sl.send_reply(483,"Too Many Hops")
		return
	end
end
 
-- SIP branch routing
function route_branch(name)
	sr.dbg("routing SIP branch from Lua [" .. name .. "]\n")
end
 
-- SIP reply routing
function route_reply(name)
	sr.dbg("routing SIP reply from Lua [" .. name .. "]\n")
end
 
-- SIP failure routing
function route_failure(name)
	sr.dbg("routing SIP failure from Lua [" .. name .. "]\n")
end
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

Reply via email to