[PATCH 04/14] s4-torture: Make sure handles are correctly initialized.

Andreas Schneider asn at samba.org
Wed Dec 4 06:01:50 MST 2013


Signed-off-by: Andreas Schneider <asn at samba.org>
---
 source4/torture/rpc/spoolss.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c
index d216e07..e795a70 100644
--- a/source4/torture/rpc/spoolss.c
+++ b/source4/torture/rpc/spoolss.c
@@ -4970,7 +4970,7 @@ static bool test_GetDriverInfo_winreg(struct torture_context *tctx,
 				      struct policy_handle *hive_handle,
 				      const char *server_name_slash)
 {
-	WERROR result;
+	WERROR result = WERR_OK;
 	union spoolss_DriverInfo info;
 	const char *driver_key;
 	struct policy_handle key_handle;
@@ -4987,6 +4987,8 @@ static bool test_GetDriverInfo_winreg(struct torture_context *tctx,
 	const char *driver_version;
 	const char *inbox_driver_version;
 
+	ZERO_STRUCT(key_handle);
+
 	torture_comment(tctx, "Testing Driver Info and winreg consistency\n");
 
 	driver_key = talloc_asprintf(tctx, "%s\\%s\\Drivers\\Version-%d\\%s",
-- 
1.8.5




More information about the samba-technical mailing list