Fail gracefully instead of crashing when attempting to write the
contents of a corrupt in-core index as a tree object.
* ps/cache-tree-w-broken-index-entry:
unpack-trees: detect mismatching number of cache-tree/index entries
cache-tree: detect mismatching number of index entries
cache-tree: refactor verification to return error codes
#define USE_THE_REPOSITORY_VARIABLE
#include "git-compat-util.h"
-#include "environment.h"
+ #include "gettext.h"
#include "hex.h"
#include "lockfile.h"
#include "tree.h"