From 05e58735ad32dc771fdca7f5a64affc48860565e Mon Sep 17 00:00:00 2001 From: Hans Ulrich Niedermann Date: Sat, 25 May 2002 19:38:02 +0000 Subject: [PATCH] Fixed *silly* typo by me (chown vs chmod) git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@4563 67ed7778-7388-44ab-90cf-0a291f65f57c --- packaging/linux-hotplug/usbcam.console | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/packaging/linux-hotplug/usbcam.console b/packaging/linux-hotplug/usbcam.console index 6ce0b45da..c7c3d0876 100755 --- a/packaging/linux-hotplug/usbcam.console +++ b/packaging/linux-hotplug/usbcam.console @@ -23,7 +23,7 @@ if [ "${ACTION}" = "add" ] && [ -f "${DEVICE}" ] then - # New code, using lock files instead of /dev/console permissions + # New code, using lock files instead of copying /dev/console permissions # This also works with non-gdm logins (e.g. on a virtual terminal) # Idea and code from Nalin Dahyabhai if [ -f /var/run/console.lock ] @@ -37,19 +37,8 @@ then fi if [ -n "$CONSOLEOWNER" ] then - chown 0000 "${DEVICE}" + chmod 0000 "${DEVICE}" chown "$CONSOLEOWNER" "${DEVICE}" - chown 0600 "${DEVICE}" + chmod 0600 "${DEVICE}" fi - - # old code, using traditional parameters and /dev/console permissions - # user="$(ls -l /dev/console | awk '/\/dev\/console$/ { print $3; }')" - # chown "${user}" "${DEVICE}" - # chmod 0600 "${DEVICE}" - - # new code, using GNU style parameters and /dev/console permissions - # CONSOLE="/dev/console" - # chown 0000 "${DEVICE}" # precaution against possible race conditions - # chown --reference "${CONSOLE}" "${DEVICE}" - # chmod --reference "${CONSOLE}" "${DEVICE}" fi