summaryrefslogtreecommitdiffstats
path: root/src/tests
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2014-06-23 19:06:52 +0200
committerJakub Hrozek <jhrozek@redhat.com>2014-07-01 11:43:31 +0200
commit132d6228d981436c5e1ca3ddf486f95ac77e46b6 (patch)
tree0c36b85cda78afceed5a198055f81b5e9a265b42 /src/tests
parent3b28d617f9af28e002b1d0a63faa90ef9e23e2ef (diff)
downloadsssd-132d6228d981436c5e1ca3ddf486f95ac77e46b6.tar.gz
sssd-132d6228d981436c5e1ca3ddf486f95ac77e46b6.tar.xz
sssd-132d6228d981436c5e1ca3ddf486f95ac77e46b6.zip
TESTS: Do not require replies from mocked sdap_get_generic_recv to be talloc contexts
While it's beneficial for the real implementation of sdap_get_generic_recv() to move memory around, the mocked implementation can just pass around pointer. Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com>
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/cmocka/common_mock_sdap.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/tests/cmocka/common_mock_sdap.c b/src/tests/cmocka/common_mock_sdap.c
index 52dcc0fad..b2b57cbd2 100644
--- a/src/tests/cmocka/common_mock_sdap.c
+++ b/src/tests/cmocka/common_mock_sdap.c
@@ -98,8 +98,7 @@ int sdap_get_generic_recv(struct tevent_req *req,
TEVENT_REQ_RETURN_ON_ERROR(req);
*reply_count = sss_mock_type(size_t);
- *reply = talloc_steal(mem_ctx,
- sss_mock_ptr_type(struct sysdb_attrs **));
+ *reply = sss_mock_ptr_type(struct sysdb_attrs **);
return EOK;
}