[sr-dev] [tracker] Task opened: usrloc: Add missing RPC commands (Attachment added)

Juha Heinanen jh at tutpro.com
Tue Apr 30 19:22:14 CEST 2013


> Details - Added commands:
> - ul.rm
> - ul.rm_contact
> - ul.flush
> - ul.add

i patched my local master and tested ul.add.  i'm using xmlrpc to make
the call and give params expires and q as int and double:

        <param>
			<value>
				<int>0</int>
			</value>
		</param>
		<param>
			<value>
				<double>0.1</double>
			</value>
		</param>

i get to syslog:

Apr 30 20:14:52 siika /usr/sbin/sip-proxy[15009]: DBG: usrloc [ul_rpc.c:557]: ret: -1 expires:0 q:0.000000

and i get back response 500 with error message:

<value><string>2:Not enough parameters or wrong format</string></value>

produced by:

	ret = rpc->scan(ctx, "dd", &ci.expires, &ci.q);
	LM_INFO("ret: %d expires:%d q:%f\n", ret, (int) ci.expires, (double) ci.q);
	if ( ret != 2) {
		rpc->fault(ctx, 500, "2:Not enough parameters or wrong format");
		return;
	}

what is wrong with those two params?  why is 0.1 convered to 0.00000?
should "dd" be changed to "df"?

-- juha



More information about the sr-dev mailing list