mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
Don't replace spaces with underscores in linux device mount points
This commit is contained in:
parent
6c0b18461c
commit
60fb76aca1
@ -422,14 +422,13 @@ class Device(DeviceConfig, DevicePlugin):
|
||||
if label is None:
|
||||
label = self.STORAGE_CARD_VOLUME_LABEL + ' 2'
|
||||
extra = 0
|
||||
label = label.replace(' ', '_')
|
||||
while True:
|
||||
q = '_(%d)'%extra if extra else ''
|
||||
if not os.path.exists('/media/'+label+q):
|
||||
break
|
||||
extra += 1
|
||||
if extra:
|
||||
label += '_(%d)'%extra
|
||||
label += ' (%d)'%extra
|
||||
|
||||
def do_mount(node, label):
|
||||
cmd = ['pmount', '-w', '-s']
|
||||
|
Loading…
x
Reference in New Issue
Block a user