Note: version 1.5.1
If syncevolution has never been run before (or ~/.config/syncevolution is removed), it fails if all the directories in the $HOME path are not world readable.
Error displayed is:
[ERROR] /home: Permission denied
chmod o=x /home
rm -rf ~/.config/syncevolution
syncevolution --daemon=no --configure --template none username= password= printChanges=1 loglevel=4 Exchange@FilesMaster
Here is an strace extract showing the case when /home is readable:
access("/home/cobb/.config/syncevolution/config.ini", F_OK) = -1 ENOENT (No such file or directory)
access("/home/cobb/.config/syncevolution/filesmaster/config.ini", F_OK) = -1 ENOENT (No such file or directory)
access("/home/cobb/.config/syncevolution/filesmaster/peers/exchange/config.ini", F_OK) = -1 ENOENT (No such file or directory)
open("/home/cobb/.config/syncevolution/.internal.ini", O_RDONLY) = -1 ENOENT (No such file or directory)
access("/home", R_OK|X_OK) = 0
access("/home/cobb", R_OK|X_OK) = 0
access("/home/cobb/.config", R_OK|X_OK) = 0
access("/home/cobb/.config/syncevolution", R_OK|W_OK|X_OK) = -1 ENOENT (No such file or directory)
mkdir("/home/cobb/.config/syncevolution", 0700) = 0
The "access("/home", R_OK|X_OK)" fails if /home is executable but not readable.
Actually, the problem is worse: it doesn't just happen if ~/.config/syncevolution does not exist. Presumably it happens when various directories or files need to be created in the .config tree.
Created attachment 117691 [details] [review]
walk bottom up instead of top down
This patch is currently pending automatic testing. Manual testing shows that it addresses the issue.
Part of for-master/master-next, will be in SyncEvolution 1.5.2.