diff --git a/hw/xwin/winauth.c b/hw/xwin/winauth.c index 09469e0a9..c16e63e87 100644 --- a/hw/xwin/winauth.c +++ b/hw/xwin/winauth.c @@ -57,23 +57,6 @@ static unsigned int g_uiAuthDataLen = 0; static char *g_pAuthData = NULL; static xcb_auth_info_t auth_info; -/* - * Code to generate a MIT-MAGIC-COOKIE-1, copied from under XCSECURITY - */ - -#ifndef XCSECURITY -XID -GenerateAuthorization(unsigned name_length, - const char *name, - unsigned data_length, - const char *data, - unsigned *data_length_return, char **data_return) -{ - return MitGenerateCookie(data_length, data, - FakeClientID(0), data_length_return, data_return); -} -#endif - /* * Generate authorization cookie for internal server clients */ diff --git a/os/auth.c b/os/auth.c index b28e7308c..a22980efd 100644 --- a/os/auth.c +++ b/os/auth.c @@ -59,9 +59,7 @@ struct protocol { AuthRstCFunc Reset; /* delete all authorization data entries */ AuthFromIDFunc FromID; /* convert ID to cookie */ AuthRemCFunc Remove; /* remove a specific cookie */ -#ifdef XCSECURITY AuthGenCFunc Generate; -#endif }; static struct protocol protocols[] = { @@ -72,9 +70,7 @@ static struct protocol protocols[] = { .Reset = MitResetCookie, .FromID = MitFromID, .Remove = MitRemoveCookie, -#ifdef XCSECURITY .Generate = MitGenerateCookie -#endif }, #ifdef HASXDMAUTH { @@ -281,8 +277,6 @@ AddAuthorization(unsigned name_length, const char *name, return 0; } -#ifdef XCSECURITY - XID GenerateAuthorization(unsigned name_length, const char *name, @@ -304,8 +298,6 @@ GenerateAuthorization(unsigned name_length, return -1; } -#endif /* XCSECURITY */ - void GenerateRandomData(int len, char *buf) {