View | Details | Raw Unified | Return to bug 1066 | Differences between
and this patch

Collapse All | Expand All

(-)gss-genr.c (-3 / +4 lines)
Lines 205-214 OM_uint32 Link Here
205
ssh_gssapi_import_name(Gssctxt *ctx, const char *host)
205
ssh_gssapi_import_name(Gssctxt *ctx, const char *host)
206
{
206
{
207
	gss_buffer_desc gssbuf;
207
	gss_buffer_desc gssbuf;
208
	char *val;
208
209
209
	gssbuf.length = sizeof("host@") + strlen(host);
210
	xasprintf(&val, "host@%s", host);
210
	gssbuf.value = xmalloc(gssbuf.length);
211
	gssbuf.value = val;
211
	snprintf(gssbuf.value, gssbuf.length, "host@%s", host);
212
	gssbuf.length = strlen(gssbuf.value);
212
213
213
	if ((ctx->major = gss_import_name(&ctx->minor,
214
	if ((ctx->major = gss_import_name(&ctx->minor,
214
	    &gssbuf, GSS_C_NT_HOSTBASED_SERVICE, &ctx->name)))
215
	    &gssbuf, GSS_C_NT_HOSTBASED_SERVICE, &ctx->name)))

Return to bug 1066