commit - ff21961dc4dad7f7d30223f9b6fbe38fa9ca0b3c
commit + b66cd6f325e3fa7ddd17ff6dd41cf6e59d04ebf5
blob - 822b842007562f4209e5385594554d50eb3be027
blob + a43dbc1f6911b315509559a874c7b729ba68d96f
--- lib/object.c
+++ lib/object.c
te = find_entry_by_name(tree, seg, seglen);
if (te == NULL) {
- err = got_error(GOT_ERR_NO_TREE_ENTRY);
+ err = got_error_path(path, GOT_ERR_NO_TREE_ENTRY);
goto done;
}
if (*id == NULL)
return got_error_from_errno("got_object_id_dup");
} else
- err = got_error(GOT_ERR_NO_TREE_ENTRY);
+ err = got_error_path(path, GOT_ERR_NO_TREE_ENTRY);
done:
if (commit)
got_object_commit_close(commit);
blob - 6234533b470b15cee07c5edc3c6b9beb606bcda1
blob + b8408a749c9e5ff2c1983eb5d006ed171fdfb6e8
--- lib/repository.c
+++ lib/repository.c
}
if (TAILQ_EMPTY(&paths)) {
- err = got_error(GOT_ERR_NO_TREE_ENTRY);
+ err = got_error_msg(GOT_ERR_NO_TREE_ENTRY,
+ "cannot create tree without any entries");
goto done;
}
blob - 0538db4eaaa0eac5a99d717327a150efac52b29b
blob + 61cc47cf16c65800bfc0db8525b875e9f2878054
--- lib/worktree.c
+++ lib/worktree.c
if (entry_name &&
got_object_tree_find_entry(tree, entry_name) == NULL) {
- err = got_error(GOT_ERR_NO_TREE_ENTRY);
+ err = got_error_path(entry_name, GOT_ERR_NO_TREE_ENTRY);
goto done;
}
te = got_object_tree_find_entry(tree, te_name);
if (te == NULL && status != GOT_STATUS_ADD &&
staged_status != GOT_STATUS_ADD) {
- err = got_error(GOT_ERR_NO_TREE_ENTRY);
+ err = got_error_path(ie->path, GOT_ERR_NO_TREE_ENTRY);
goto done;
}
}
blob - 80b89ada1f0b16289f55b21fccf251a40d0bd17b
blob + 29f55aa5a7d96f3b060398ff0db5ae16d8e4f3e1
--- regress/cmdline/update.sh
+++ regress/cmdline/update.sh
(cd $testroot/repo && git rm -q alpha epsilon/zeta)
git_commit $testroot/repo -m "removed two files"
- echo "got: no such entry found in tree" \
+ echo "got: /alpha: no such entry found in tree" \
> $testroot/stderr.expected
(cd $testroot/wt && got update alpha epsilon/zeta 2> $testroot/stderr)