### Please describe the problem.
I have a V6 annex in adjusted branch with a submodule, which also is a V6 annex in adjusted branch.
There staged changes in the superproject, while the submodule is clean. Calling git-annex-sync in the superproject now leads to:

[[!format sh """
% git annex sync
commit  (recording state in git...)

[adjusted/master(unlocked) 3c8d350] git-annex in me@mycomputer:/tmp/datalad_temp_test_AnnexRepo_statusGmqM5E
 4 files changed, 4 insertions(+), 2 deletions(-)
 create mode 100644 fifth
 create mode 100644 sub/third
ok
fatal: entry 'submod' object type (blob) doesn't match mode type (commit)

git-annex: user error (git ["--git-dir=.git","--work-tree=.","--literal-pathspecs","mktree","--batch","-z"] exited 128)
failed
git-annex: sync: 1 failed
"""]]

### What steps will reproduce the problem?

Sadly I wasn't able to reproduce it outside the datalad test it is happening in.
I will provide the steps to achieve that situation, whenever I figured them out.
But may be just the error message is sufficient to address the problem ...

### What version of git-annex are you using? On what operating system?
[[!format sh """
% git annex version
git-annex version: 6.20170307+gitg24ade8a25-1~ndall+1
build flags: Assistant Webapp Pairing Testsuite S3(multipartupload)(storageclasses) WebDAV Inotify DBus DesktopNotify ConcurrentOutput TorrentParser MagicMime Feeds Quvi
key/value backends: SHA256E SHA256 SHA512E SHA512 SHA224E SHA224 SHA384E SHA384 SHA3_256E SHA3_256 SHA3_512E SHA3_512 SHA3_224E SHA3_224 SHA3_384E SHA3_384 SKEIN256E SKEIN256 SKEIN512E SKEIN512 SHA1E SHA1 MD5E MD5 WORM URL
remote types: git gcrypt p2p S3 bup directory rsync web bittorrent webdav tahoe glacier ddar hook external
local repository version: 6
supported repository versions: 3 5 6
upgrade supported from repository 
"""]]
### Please provide any additional information below.

[[!format sh """
# If you can, paste a complete transcript of the problem occurring here.
# If the problem is with the git-annex assistant, paste in .git/annex/daemon.log


# End of transcript or log.
"""]]

### Have you had any luck using git-annex before? (Sometimes we get tired of reading bug reports all day and a lil' positive end note does wonders)


[[ben]]
