krb5 commit: Clean up gssrpc timeout code

Greg Hudson ghudson at mit.edu
Tue Mar 17 14:54:54 EDT 2015


https://github.com/krb5/krb5/commit/e321a9d23c4475ba105a6e892624a65940e7aed2
commit e321a9d23c4475ba105a6e892624a65940e7aed2
Author: Greg Hudson <ghudson at mit.edu>
Date:   Sat Mar 14 14:29:21 2015 -0400

    Clean up gssrpc timeout code
    
    Revert b8b7bd63231094a3583847853bf60cb002781161 (for #6120) now that
    we are setting the kadmin client timeout the appropriate way.
    
    In clnt_create(), do not set a timeout after creating the handle;
    doing so defeats the purpose of keeping track of whether the caller
    has set a handle timeout.

 src/lib/kadm5/clnt/client_rpc.c |    2 +-
 src/lib/rpc/clnt_generic.c      |    5 -----
 2 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/src/lib/kadm5/clnt/client_rpc.c b/src/lib/kadm5/clnt/client_rpc.c
index e11346d..0d2f953 100644
--- a/src/lib/kadm5/clnt/client_rpc.c
+++ b/src/lib/kadm5/clnt/client_rpc.c
@@ -10,7 +10,7 @@
 #endif
 
 /* Default timeout can be changed using clnt_control() */
-static struct timeval TIMEOUT = { 120, 0 };
+static struct timeval TIMEOUT = { 25, 0 };
 
 generic_ret *
 create_principal_2(cprinc_arg *argp, CLIENT *clnt)
diff --git a/src/lib/rpc/clnt_generic.c b/src/lib/rpc/clnt_generic.c
index 595c5f2..79831e1 100644
--- a/src/lib/rpc/clnt_generic.c
+++ b/src/lib/rpc/clnt_generic.c
@@ -94,17 +94,12 @@ clnt_create(
 		if (client == NULL) {
 			return (NULL);
 		}
-		tv.tv_sec = 120;
-		clnt_control(client, CLSET_TIMEOUT, &tv);
 		break;
 	case IPPROTO_TCP:
 		client = clnttcp_create(&sockin, prog, vers, &sock, 0, 0);
 		if (client == NULL) {
 			return (NULL);
 		}
-		tv.tv_sec = 120;
-		tv.tv_usec = 0;
-		clnt_control(client, CLSET_TIMEOUT, &tv);
 		break;
 	default:
 		rpc_createerr.cf_stat = RPC_SYSTEMERROR;


More information about the cvs-krb5 mailing list