[Pkg-dkms-maint] Bug#666023: [PATCH] do not fail if /lib/modules does not exist

Andreas Beckmann debian at abeckmann.de
Wed Jun 13 17:41:14 UTC 2012


---
 dkms_common.postinst |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dkms_common.postinst b/dkms_common.postinst
index d8cf3a7..0c8cfc1 100644
--- a/dkms_common.postinst
+++ b/dkms_common.postinst
@@ -146,7 +146,7 @@ if [ -z "$NAME" ] || [ -z "$VERSION" ]; then
     exit 1
 fi
 
-KERNELS=$(ls /lib/modules/)
+KERNELS=$(ls /lib/modules/ 2>/dev/null || true)
 CURRENT_KERNEL=$(uname -r)
 
 #We never want to keep an older version side by side to prevent conflicts
-- 
1.7.10






More information about the Pkg-dkms-maint mailing list