tags 644310 + patch thanks On Tue, Oct 04, 2011 at 11:47:46PM +0200, bi...@debian.org wrote: > During an automated test your package ccstools was flagged to > reference files/directories matching /dev/.udev A log of this test > can be found at [2]. > > In most cases checking for /dev/.udev is used to determine if udev is > active. This check no longer works with udev using /run/udev now. > > In most cases, checking for udev being installed is not appropriate > and should be avoided.
Please find attached a patch to replace the existing checks for /dev/.udev* with /run/udev. Note that I'm not familiar with ccstools/tomoyo, so this will need checking. In particular, note that the new udev directory will only be present after you have updated your initramfs; given that this code is looking at what is present on a running system, this should be OK? Regards, Roger -- .''`. Roger Leigh : :' : Debian GNU/Linux http://people.debian.org/~rleigh/ `. `' Printing on GNU/Linux? http://gutenprint.sourceforge.net/ `- GPG Public Key: 0x25BFB848 Please GPG sign your mail.
diff -urN ccstools-1.7.3-20110401.orig/init_policy.c ccstools-1.7.3-20110401/init_policy.c --- ccstools-1.7.3-20110401.orig/init_policy.c 2012-01-18 22:55:49.206522649 +0000 +++ ccstools-1.7.3-20110401/init_policy.c 2012-01-18 22:58:05.124328450 +0000 @@ -811,19 +811,17 @@ { /* Make patterns for udev(8). */ struct stat buf; - if (!lstat("/dev/.udev", &buf) && S_ISDIR(buf.st_mode)) { - echo("file_pattern /dev/.udev/\\*"); - echo("file_pattern /dev/.udev/\\*/"); - echo("file_pattern /dev/.udev/\\*/\\*"); - echo("file_pattern /dev/.udev/\\*/\\*/"); - echo("file_pattern /dev/.udev/\\*/\\*/\\*"); - echo("file_pattern /dev/.udev/\\*/\\*/\\*/"); - echo("file_pattern /dev/.udev/\\*/\\*/\\*/\\*"); - echo("file_pattern /dev/.udev/\\*/\\*/\\*/\\*/"); - echo("file_pattern /dev/.udev/\\*/\\*/\\*/\\*/\\*"); + if (!lstat("/run/udev", &buf) && S_ISDIR(buf.st_mode)) { + echo("file_pattern /run/udev/\\*"); + echo("file_pattern /run/udev/\\*/"); + echo("file_pattern /run/udev/\\*/\\*"); + echo("file_pattern /run/udev/\\*/\\*/"); + echo("file_pattern /run/udev/\\*/\\*/\\*"); + echo("file_pattern /run/udev/\\*/\\*/\\*/"); + echo("file_pattern /run/udev/\\*/\\*/\\*/\\*"); + echo("file_pattern /run/udev/\\*/\\*/\\*/\\*/"); + echo("file_pattern /run/udev/\\*/\\*/\\*/\\*/\\*"); } - if (!lstat("/dev/.udevdb", &buf) && S_ISDIR(buf.st_mode)) - echo("file_pattern /dev/.udevdb/\\*"); } static void make_patterns_for_sh(void)