Skip to content

Commit

Permalink
Assign result of talloc_steal
Browse files Browse the repository at this point in the history
  • Loading branch information
alandekok committed Apr 29, 2014
1 parent 7fda18c commit 70b04d6
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/lib/cbuff.c
Expand Up @@ -113,8 +113,7 @@ void fr_cbuff_rp_insert(fr_cbuff_t *cbuff, void *obj)
TALLOC_FREE(cbuff->elem[cbuff->in]);
}

cbuff->elem[cbuff->in] = obj;
talloc_steal(cbuff, obj);
cbuff->elem[cbuff->in] = talloc_steal(cbuff, obj);

cbuff->in = (cbuff->in + 1) & cbuff->size;

Expand Down

0 comments on commit 70b04d6

Please sign in to comment.