summaryrefslogtreecommitdiff
path: root/src/dir.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/dir.cpp')
-rw-r--r--src/dir.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/dir.cpp b/src/dir.cpp
index cee26f0..c590450 100644
--- a/src/dir.cpp
+++ b/src/dir.cpp
@@ -19,14 +19,9 @@ GitFS::Directory::getSubtree() const
subTreeCache = repo->tree;
}
else {
- try {
- auto e = Git::TreeEntryByPath(repo->tree, path);
- if (!S_ISDIR(git_tree_entry_filemode(e.get()))) throw NetFS::SystemError(ENOTDIR);
- subTreeCache = Git::TreeLookup(repo->repo, *git_tree_entry_id(e.get()));
- }
- catch (const Git::Error & e) {
- Git::ErrorToSystemError(e);
- }
+ auto e = Git::TreeEntryByPath(repo->tree, path);
+ if (!S_ISDIR(git_tree_entry_filemode(e.get()))) throw NetFS::SystemError(ENOTDIR);
+ subTreeCache = Git::TreeLookup(repo->repo, *git_tree_entry_id(e.get()));
}
subTreeCacheRootId = *git_tree_id(repo->tree.get());
}