summaryrefslogtreecommitdiff
path: root/nsswitch/libwbclient/tests
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-04-10 15:36:01 +0200
committerVolker Lendecke <vl@samba.org>2010-04-19 14:27:17 +0200
commit4f5100bcb2d720351d7ba1cc721e234236e69ea3 (patch)
tree15c1906708c45b48abee4e9e7bf46afdc404fecd /nsswitch/libwbclient/tests
parent679e7ef6e68c9d355cc5f1764600ee8999b3e021 (diff)
downloadsamba-4f5100bcb2d720351d7ba1cc721e234236e69ea3.tar.gz
samba-4f5100bcb2d720351d7ba1cc721e234236e69ea3.tar.bz2
samba-4f5100bcb2d720351d7ba1cc721e234236e69ea3.zip
libwbclient: Simplify test_wbc_domain_info a bit
Diffstat (limited to 'nsswitch/libwbclient/tests')
-rw-r--r--nsswitch/libwbclient/tests/wbclient.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/nsswitch/libwbclient/tests/wbclient.c b/nsswitch/libwbclient/tests/wbclient.c
index 511405010d..f998746c41 100644
--- a/nsswitch/libwbclient/tests/wbclient.c
+++ b/nsswitch/libwbclient/tests/wbclient.c
@@ -173,18 +173,16 @@ static bool test_wbc_guidtostring(struct torture_context *tctx)
static bool test_wbc_domain_info(struct torture_context *tctx)
{
- const char *domain_name = NULL;
struct wbcDomainInfo *info;
struct wbcInterfaceDetails *details;
torture_assert_wbc_ok(tctx, wbcInterfaceDetails(&details),
"wbcInterfaceDetails failed");
-
- domain_name = talloc_strdup(tctx, details->netbios_domain);
+ torture_assert_wbc_ok(
+ tctx, wbcDomainInfo(details->netbios_domain, &info),
+ "wbcDomainInfo failed");
wbcFreeMemory(details);
- torture_assert_wbc_ok(tctx, wbcDomainInfo(domain_name, &info),
- "wbcDomainInfo failed");
torture_assert(tctx, info,
"wbcDomainInfo returned NULL pointer");
wbcFreeMemory(info);