Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
diff-lib.c: rename check_work_tree_entity()
author
Junio C Hamano
<gitster@pobox.com>
Sun, 4 May 2008 00:23:46 +0000
(17:23 -0700)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 5 May 2008 00:41:27 +0000
(17:41 -0700)
The function is about checking for removed work tree item, so name it
accordingly to avoid future confusion.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
diff-lib.c
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
1392a37
)
diff --git
a/diff-lib.c
b/diff-lib.c
index e0ebcdcf5434b3281fa81fcf1330ece2ddc94fba..4a3e25536c894dfb928754e6314a400d39c6f9ad 100644
(file)
--- a/
diff-lib.c
+++ b/
diff-lib.c
@@
-347,7
+347,7
@@
int run_diff_files_cmd(struct rev_info *revs, int argc, const char **argv)
* exists for ce that is a submodule -- it is a submodule that is not
* checked out). Return negative for an error.
*/
* exists for ce that is a submodule -- it is a submodule that is not
* checked out). Return negative for an error.
*/
-static int check_
work_tree_entity
(const struct cache_entry *ce, struct stat *st, char *symcache)
+static int check_
removed
(const struct cache_entry *ce, struct stat *st, char *symcache)
{
if (lstat(ce->name, st) < 0) {
if (errno != ENOENT && errno != ENOTDIR)
{
if (lstat(ce->name, st) < 0) {
if (errno != ENOENT && errno != ENOTDIR)
@@
-421,7
+421,7
@@
int run_diff_files(struct rev_info *revs, unsigned int option)
memset(&(dpath->parent[0]), 0,
sizeof(struct combine_diff_parent)*5);
memset(&(dpath->parent[0]), 0,
sizeof(struct combine_diff_parent)*5);
- changed = check_
work_tree_entity
(ce, &st, symcache);
+ changed = check_
removed
(ce, &st, symcache);
if (!changed)
dpath->mode = ce_mode_from_stat(ce, st.st_mode);
else {
if (!changed)
dpath->mode = ce_mode_from_stat(ce, st.st_mode);
else {
@@
-485,7
+485,7
@@
int run_diff_files(struct rev_info *revs, unsigned int option)
if (ce_uptodate(ce))
continue;
if (ce_uptodate(ce))
continue;
- changed = check_
work_tree_entity
(ce, &st, symcache);
+ changed = check_
removed
(ce, &st, symcache);
if (changed) {
if (changed < 0) {
perror(ce->name);
if (changed) {
if (changed < 0) {
perror(ce->name);
@@
-543,7
+543,7
@@
static int get_stat_data(struct cache_entry *ce,
if (!cached) {
int changed;
struct stat st;
if (!cached) {
int changed;
struct stat st;
- changed = check_
work_tree_entity
(ce, &st, cbdata->symcache);
+ changed = check_
removed
(ce, &st, cbdata->symcache);
if (changed < 0)
return -1;
else if (changed) {
if (changed < 0)
return -1;
else if (changed) {