Skip to content

Commit

Permalink
dmq_usrloc: proper handle of not found urecord by uuid
Browse files Browse the repository at this point in the history
- return code is negative and in this case is not locking the slot
  • Loading branch information
miconda committed Oct 23, 2015
1 parent 922e581 commit 13cde2b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/dmq_usrloc/usrloc_sync.c
Expand Up @@ -197,12 +197,12 @@ void usrloc_get_all_ucontact(dmq_node_t* node)
memcpy( &aorhash, cp, sizeof(aorhash));
cp = (char*)cp + sizeof(aorhash);

r = 0;
ptr = 0;
res = dmq_ul.get_urecord_by_ruid(_d, aorhash, &ruid, &r, &ptr);
aor = r->aor;
if (res > 0) {
if (res < 0) {
LM_DBG("'%.*s' Not found in usrloc\n", aor.len, ZSW(aor.s));
dmq_ul.release_urecord(r);
dmq_ul.unlock_udomain(_d, &aor);
continue;
}
LM_DBG("- AoR: %.*s AoRhash=%d Flags=%d\n", aor.len, aor.s, aorhash, flags);
Expand Down

0 comments on commit 13cde2b

Please sign in to comment.