]> www.vanbest.org Git - motioneye-debian/commitdiff
only writable partitions are listed as available
authorCalin Crisan <ccrisan@gmail.com>
Sat, 5 Jul 2014 17:33:56 +0000 (20:33 +0300)
committerCalin Crisan <ccrisan@gmail.com>
Sat, 5 Jul 2014 17:33:56 +0000 (20:33 +0300)
src/diskctl.py

index e570151f658d7c7d720cd033efecbd3bf0df5f3d..7b3f67538c1cc409f6bd457d862fc0bfc1ec44a2 100644 (file)
@@ -37,10 +37,13 @@ def _list_mounts():
             mount_point = parts[1]
             fstype = parts[2]
             opts = parts[3]
+            
+            if not os.access(mount_point, os.W_OK):
+                continue
 
             if fstype == 'fuseblk':
                 fstype = 'ntfs' # most likely'
-
+                
             logging.debug('found mount "%s" at "%s"' % (target, mount_point))
             
             mounts.append({