~ubuntu-branches/ubuntu/intrepid/git-core/intrepid-updates

« back to all changes in this revision

Viewing changes to builtin-diff-index.c

  • Committer: Package Import Robot
  • Author(s): Gerrit Pape
  • Date: 2007-04-22 13:31:05 UTC
  • mfrom: (1.1.14)
  • Revision ID: package-import@ubuntu.com-20070422133105-tkmhz328g2p0epz1
Tags: 1:1.5.1.2-1
* new upstream point release.
* debian/changelog.upstream: upstream changes taken from mailing list
  announcement.

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
        struct rev_info rev;
15
15
        int cached = 0;
16
16
        int i;
 
17
        int result;
17
18
 
18
19
        init_revisions(&rev, prefix);
19
20
        git_config(git_default_config); /* no "diff" UI options */
38
39
        if (rev.pending.nr != 1 ||
39
40
            rev.max_count != -1 || rev.min_age != -1 || rev.max_age != -1)
40
41
                usage(diff_cache_usage);
41
 
        return run_diff_index(&rev, cached);
 
42
        if (read_cache() < 0) {
 
43
                perror("read_cache");
 
44
                return -1;
 
45
        }
 
46
        result = run_diff_index(&rev, cached);
 
47
        return rev.diffopt.exit_with_status ? rev.diffopt.has_changes: result;
42
48
}