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

Victor Seva linuxmaniac at torreviejawireless.org
Tue Apr 30 20:06:31 CEST 2013


2013/4/30 Juha Heinanen <jh at tutpro.com>:
> i tried that and the error disappeared, but value of q (0.1) does not
> look good:
>
> Apr 30 20:45:43 siika /usr/sbin/sip-proxy[15562]: DBG: usrloc [ul_rpc.c:557]: ret: 2 expires:0 q:-1717986918.000000
>
> next i got error:
>
> 3:Not enough parameters or wrong format
>
> most likely because i gave unused param as int rather than string.  the
> types of the params should be documented in README.

can you test this, please:

diff --git a/modules/usrloc/ul_rpc.c b/modules/usrloc/ul_rpc.c
index d9535cb..5675081 100644
--- a/modules/usrloc/ul_rpc.c
+++ b/modules/usrloc/ul_rpc.c
@@ -559,7 +559,7 @@ static void ul_rpc_add(rpc_t* rpc, void* ctx)
                rpc->fault(ctx, 500, "2:Not enough parameters or wrong format");
                return;
        }
-       ret = rpc->scan(ctx, "Sddd", &useless, &ci.flags, &ci.cflags,
&ci.methods);
+       ret = rpc->scan(ctx, ".Sddd", &useless, &ci.flags, &ci.cflags,
&ci.methods);
        LM_DBG("ret: %d useless:%.*s flags:%d bflags:%d methods:%d\n",
ret, useless.len, useless.s, ci.flags, ci.cflags, (int)ci.methods);
        if ( ret != 4) {
                rpc->fault(ctx, 500, "3:Not enough parameters or wrong format");



More information about the sr-dev mailing list