removePack(p);
} else if (e instanceof FileNotFoundException) {
if (p.getPackFile().exists()) {
- warnTmpl = JGitText.get().packInaccessible;
+ errTmpl = JGitText.get().packInaccessible;
+ transientErrorCount = p.incrementTransientErrorCount();
} else {
warnTmpl = JGitText.get().packWasDeleted;
+ removePack(p);
}
- removePack(p);
- } else if (FileUtils.isStaleFileHandle(e)) {
+ } else if (FileUtils.isStaleFileHandleInCausalChain(e)) {
warnTmpl = JGitText.get().packHandleIsStale;
removePack(p);
+ } else {
+ transientErrorCount = p.incrementTransientErrorCount();
}
if (warnTmpl != null) {
if (LOG.isDebugEnabled()) {