summaryrefslogtreecommitdiff
path: root/gss-serv.c
diff options
context:
space:
mode:
Diffstat (limited to 'gss-serv.c')
-rw-r--r--gss-serv.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gss-serv.c b/gss-serv.c
index e61b37bec..5c599247b 100644
--- a/gss-serv.c
+++ b/gss-serv.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gss-serv.c,v 1.26 2014/02/26 20:28:44 djm Exp $ */ 1/* $OpenBSD: gss-serv.c,v 1.27 2014/07/03 03:34:09 djm Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 2001-2003 Simon Wilkinson. All rights reserved. 4 * Copyright (c) 2001-2003 Simon Wilkinson. All rights reserved.
@@ -97,13 +97,13 @@ static OM_uint32
97ssh_gssapi_acquire_cred(Gssctxt *ctx) 97ssh_gssapi_acquire_cred(Gssctxt *ctx)
98{ 98{
99 OM_uint32 status; 99 OM_uint32 status;
100 char lname[MAXHOSTNAMELEN]; 100 char lname[NI_MAXHOST];
101 gss_OID_set oidset; 101 gss_OID_set oidset;
102 102
103 gss_create_empty_oid_set(&status, &oidset); 103 gss_create_empty_oid_set(&status, &oidset);
104 gss_add_oid_set_member(&status, ctx->oid, &oidset); 104 gss_add_oid_set_member(&status, ctx->oid, &oidset);
105 105
106 if (gethostname(lname, MAXHOSTNAMELEN)) { 106 if (gethostname(lname, sizeof(lname))) {
107 gss_release_oid_set(&status, &oidset); 107 gss_release_oid_set(&status, &oidset);
108 return (-1); 108 return (-1);
109 } 109 }