From f818a5937d95dd2200b92cf16b21b421a1292fae Mon Sep 17 00:00:00 2001 From: Ray Strode Date: Mar 17 2009 18:32:19 +0000 Subject: - Clean up empty auth dirs so they don't hang around forever (bug 485974) --- diff --git a/gdm-2.26.0-clean-up-auth-entries.patch b/gdm-2.26.0-clean-up-auth-entries.patch new file mode 100644 index 0000000..d925ad7 --- /dev/null +++ b/gdm-2.26.0-clean-up-auth-entries.patch @@ -0,0 +1,44 @@ +--- a/daemon/gdm-display-access-file.c (revision 6783) ++++ b/daemon/gdm-display-access-file.c (working copy) +@@ -220,6 +220,31 @@ _get_uid_and_gid_for_user (const char *u + return TRUE; + } + ++static void ++clean_up_stale_auth_subdirs (void) ++{ ++ GDir *dir; ++ const char *filename; ++ ++ dir = g_dir_open (GDM_XAUTH_DIR, 0, NULL); ++ ++ if (dir == NULL) { ++ return; ++ } ++ ++ while ((filename = g_dir_read_name (dir)) != NULL) { ++ char *path; ++ ++ path = g_build_filename (GDM_XAUTH_DIR, filename, NULL); ++ ++ /* Will only succeed if the directory is empty ++ */ ++ g_rmdir (path); ++ g_free (path); ++ } ++ g_dir_close (dir); ++} ++ + static FILE * + _create_xauth_file_for_user (const char *username, + char **filename, +@@ -262,6 +287,9 @@ _create_xauth_file_for_user (const char + } else { + /* if it does exist make sure it has correct mode 01775 */ + g_chmod (GDM_XAUTH_DIR, S_ISVTX | S_IRWXU |S_IRWXG | S_IROTH | S_IXOTH); ++ ++ /* and clean up any stale auth subdirs */ ++ clean_up_stale_auth_subdirs (); + } + + if (!_get_uid_and_gid_for_user (username, &uid, &gid)) { diff --git a/gdm.spec b/gdm.spec index 2f8d3a8..eb80404 100644 --- a/gdm.spec +++ b/gdm.spec @@ -15,7 +15,7 @@ Summary: The GNOME Display Manager Name: gdm Version: 2.26.0 -Release: 1%{?dist} +Release: 2%{?dist} Epoch: 1 License: GPLv2+ Group: User Interface/X @@ -94,7 +94,9 @@ Patch14: gdm-2.25.2-multistack-but-boring.patch Patch15: gdm-2.25.2-start-faster.patch Patch16: gdm-2.25.2-dont-depend-on-hostname.patch -Patch17: gdm-2.25.2-maybe-work-around-gcc-bug.patch + +# http://bugzilla.redhat.com/show_bug.cgi?id=485974 +Patch17: gdm-2.26.0-clean-up-auth-entries.patch # Fedora-specific Patch99: gdm-2.23.1-fedora-logo.patch @@ -124,7 +126,7 @@ multiple simulanteous logged in users. %patch14 -p1 -b .multistack-but-boring %patch15 -p1 -b .start-faster %patch16 -p1 -b .dont-depend-on-hostname -#%patch17 -p1 -b .maybe-work-around-gcc-bug +%patch17 -p1 -b .clean-up-auth-entries %patch99 -p1 -b .fedora-logo @@ -348,6 +350,10 @@ fi %{_datadir}/gnome-2.0/ui/GNOME_FastUserSwitchApplet.xml %changelog +* Mon Mar 16 2009 Ray Strode - 1:2.26.0-2 +- Clean up empty auth dirs so they don't hang around forever + (bug 485974) + * Mon Mar 16 2009 Ray Strode - 1:2.26.0-1 - Update to 2.26.0 - Drop gcc workaround. it might not be needed now.