Bug #2131

streamline code to detect syncing and copying

Added by hans over 4 years ago. Updated about 4 years ago.

Status:ClosedStart date:10/18/2013
Priority:NormalDue date:
Assignee:abeluck% Done:

0%

Category:-
Target version:0.2
Component:

Description

The mount is definitely there when I run this, but I get this error:

$ echo test|openssl aes-256-cbc -pass stdin -in /tmp/tmpWkjlkajslKAL -out '/home/hans/.gvfs/mtp/Internalstorage/otr_keystore.ofcaes'
/home/hans/.gvfs/mtp/Internal storage/otr_keystore.ofcaes: No such file or directory
140285518091936:error:02001002:system library:fopen:No such file or directory:bss_file.c:398:fopen('/home/hans/.gvfs/mtp/Internal storage/otr_keystore.ofcaes','w')
140285518091936:error:20074002:BIO routines:FILE_CTRL:system lib:bss_file.c:400:

It behaves oddly even with a touch from the terminal:

$ touch /home/hans/.gvfs/mtp/Internal storage/wt
touch: setting times of `wt': Operation not supported

Associated revisions

Revision e40aff65
Added by Hans-Christoph Steiner about 4 years ago

reorg device detection and sync logic to account for many techniques

When this code was written there were only two techniques supported: GVFS
mount and direct MTP. But we've found that there are many approaches that
KeySync should use, so the core app logic should better reflect that.

fixes #2131
refs #2125

Revision e40aff65
Added by Hans-Christoph Steiner about 4 years ago

reorg device detection and sync logic to account for many techniques

When this code was written there were only two techniques supported: GVFS
mount and direct MTP. But we've found that there are many approaches that
KeySync should use, so the core app logic should better reflect that.

fixes #2131
refs #2125

History

#1 Updated by hans over 4 years ago

util.get_keystore_savedir() should always return the tempfile.mkdtemp() result, then util.mtp_is_mounted() should have the MTP path finding logic from util.get_keystore_savedir() so that it finds actual mount points like ~/.gvfs/mtp/Internal storage rather than just ~/.gvfs/mtp, which is never the direct mountpoint, but instead contains them.

Then openssl will write to the temp dir, and the file should be copied into place in the gvfs MTP mount dir. Hopefully that will fix it.

#2 Updated by abeluck over 4 years ago

  • Assignee set to hans

Yes, I think this is a good idea. It has the side effect of making things cleaner, and will make the KDE KIO implementation less intrusive.

#3 Updated by hans about 4 years ago

  • Subject changed from openssl sometimes can't write to the gvfs mount to streamline code to detect syncing and copying
  • Status changed from New to Resolved
  • Assignee changed from hans to abeluck

#4 Updated by abeluck about 4 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF