object file 相关错误
本地的repo在执行git log和git pull命令时出现了如下关于object file的错误:
git log 错误
>>>> $ git log
error: object file .git/objects/7b/40exxx is empty
error: object file .git/objects/7b/40exxx is empty
fatal: loose object 7b40exxx (stored in .git/objects/7b/40exxx) is corrupt
git pull 错误
>>>> $ git pull
error: object file .git/objects/7b/40exxx is empty
error: object file .git/objects/7b/40exxx is empty
remote: Counting objects: 479, done
remote: Finding sources: 100% (1388/1388)
error: object file .git/objects/7b/40exxx is empty
fatal: cannot read existing object info 40exxx
fatal: index-pack failed
warning: unable to unlink '(null)': Bad address
解决方法 Solution
|
|
再次尝试git log 和 git pull命令。一切正常后删除备份 rm -r .git-bak。