linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fix usb remover
@ 2005-02-07 22:35 Bill Nottingham
  2005-02-07 22:52 ` David Brownell
  2005-02-07 22:57 ` Bill Nottingham
  0 siblings, 2 replies; 3+ messages in thread
From: Bill Nottingham @ 2005-02-07 22:35 UTC (permalink / raw)
  To: linux-hotplug

[-- Attachment #1: Type: text/plain, Size: 84 bytes --]

Can't use readlink, as it's reading something that no longer exists
on remove.

Bill

[-- Attachment #2: hotplug-usb-remove.patch --]
[-- Type: text/plain, Size: 467 bytes --]

--- hotplug-2004_04_01/etc/hotplug/usb.agent	2004-04-01 12:38:59.000000000 -0500
+++ /home/notting/usb.agent	2004-11-16 12:42:26.584166935 -0500
@@ -344,7 +344,7 @@
 #
 if [ "$DEVPATH" != "" ]; then
   # probably, 2.6.x
-  REMOVER=/var/run/usb/$(readlink -f $SYSFS/$DEVPATH | sed -e 's;/;%;g')
+  REMOVER=/var/run/usb/$(echo -n $SYSFS/$DEVPATH | sed -e 's;/;%;g')
 elif [ "$DEVICE" != "" ]; then
   # 2.4.x?
   REMOVER=/var/run/usb/$(echo $DEVICE | sed -e 's;/;%;g')

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-02-07 22:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-02-07 22:35 [PATCH] fix usb remover Bill Nottingham
2005-02-07 22:52 ` David Brownell
2005-02-07 22:57 ` Bill Nottingham

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).