d0eeced
From 40d3be22f6e518e4354aa7c3d0278291fcbed32f Mon Sep 17 00:00:00 2001
d0eeced
From: Sumit Bose <sbose@redhat.com>
d0eeced
Date: Fri, 5 Jun 2020 17:06:58 +0200
d0eeced
Subject: [PATCH] delete: do not exit if keytab cannot be read
d0eeced
d0eeced
Reading the keytab is not required when deleting a host object in AD. It
d0eeced
is only needed in the case where the host was added with a manual set
d0eeced
NetBIOS name (--computer-name option) which does not match the short
d0eeced
hostname and no computer name was given at the delete-computer command
d0eeced
line.
d0eeced
d0eeced
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1840752
d0eeced
---
d0eeced
 tools/computer.c | 2 --
d0eeced
 1 file changed, 2 deletions(-)
d0eeced
d0eeced
diff --git a/tools/computer.c b/tools/computer.c
d0eeced
index 292c4d8..a90c4b2 100644
d0eeced
--- a/tools/computer.c
d0eeced
+++ b/tools/computer.c
d0eeced
@@ -952,8 +952,6 @@ adcli_tool_computer_delete (adcli_conn *conn,
d0eeced
 	if (res != ADCLI_SUCCESS) {
d0eeced
 		warnx ("couldn't lookup domain info from keytab: %s",
d0eeced
 		       adcli_get_last_error ());
d0eeced
-		adcli_enroll_unref (enroll);
d0eeced
-		return -res;
d0eeced
 	}
d0eeced
 
d0eeced
 	res = adcli_conn_connect (conn);
d0eeced
-- 
d0eeced
2.26.2
d0eeced