[Pkg-utopia-maintainers] Bug#561106: Bug#561106: Patch for Bug#561106: consolekit: console-kit-daemo segfaults at startup

Michael Biebl biebl at debian.org
Sat Dec 19 19:32:53 UTC 2009


Michel Messerschmidt wrote:
> I had the same problem with segfaults due to a .svn subdirectory in 
> /etc/ConsoleKit/seats.d/
> 
> This patch fixed it for me:
> mic at ryu:~/src/debian/consolekit$ diff -ur consolekit-0.4.1.orig/ consolekit-0.4.1.new/
> diff -ur consolekit-0.4.1.orig/src/ck-manager.c consolekit-0.4.1.new/src/ck-manager.c
> --- consolekit-0.4.1.orig/src/ck-manager.c	2009-09-24 07:10:07.000000000 +0200
> +++ consolekit-0.4.1.new/src/ck-manager.c	2009-12-19 14:10:42.000000000 +0100
> @@ -2476,7 +2476,9 @@
>          while ((file = g_dir_read_name (d)) != NULL) {
>                  char *path;
>                  path = g_build_filename (CK_SEAT_DIR, file, NULL);
> -                add_seat_for_file (manager, path);
> +                if (!g_file_test (path, G_FILE_TEST_IS_DIR)) {
> +                    add_seat_for_file (manager, path);
> +                }
>                  g_free (path);
>          }

Thanks for the patch, but I think we should go even further and also filter out
temporary/backup files created by editors or dpkg backup files.

Maybe it's best to only load files with a certain file extension.

@Jon: should we limit the files we load from /etc/ConsoleKit/ to certain
extensions only:
run-seat.d, run-session.d: *.ck
seat.d: *.seat

I.e. we use a whitelist for files we load.
Or should we use the blacklist approach an filter out (know)
temporary/backup/hidden files and directories?

Cheers,
Michael

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-utopia-maintainers/attachments/20091219/4aef77a1/attachment.pgp>


More information about the Pkg-utopia-maintainers mailing list