slitaz-tools rev 834

tazhw: detect_usb_devices needs at least one usb device
author Pascal Bellard <pascal.bellard@slitaz.org>
date Wed Feb 19 10:55:44 2014 +0000 (2014-02-19)
parents 4a0af01c775c
children b0d5fdb1e5f3
files tinyutils/tazhw
line diff
     1.1 --- a/tinyutils/tazhw	Sat Feb 15 13:28:03 2014 +0100
     1.2 +++ b/tinyutils/tazhw	Wed Feb 19 10:55:44 2014 +0000
     1.3 @@ -104,7 +104,7 @@
     1.4  
     1.5  # Detect all USB devices.
     1.6  detect_usb_devices() {
     1.7 -	if [ -d /sys/bus/usb ]; then
     1.8 +	if [ -e /sys/bus/usb/devices/usb/usb1 ]; then
     1.9  		for product in /sys/bus/usb/devices/*/product
    1.10  		do
    1.11  			path=$(dirname $product)