From: Junio C Hamano Date: Wed, 16 Mar 2011 07:17:05 +0000 (-0700) Subject: Merge branch 'nd/struct-pathspec' X-Git-Tag: v1.7.5-rc0~68 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/276e017f2f632e9bd954bd5a6b794fe0865a5f37?ds=inline;hp=-c Merge branch 'nd/struct-pathspec' * nd/struct-pathspec: declare 1-bit bitfields to be unsigned --- 276e017f2f632e9bd954bd5a6b794fe0865a5f37 diff --combined cache.h index c4ef999762,edd5b5ad8f..8d18a113cd --- a/cache.h +++ b/cache.h @@@ -503,20 -503,20 +503,20 @@@ extern int ie_modified(const struct ind struct pathspec { const char **raw; /* get_pathspec() result, not freed by free_pathspec() */ int nr; - int has_wildcard:1; - int recursive:1; + unsigned int has_wildcard:1; + unsigned int recursive:1; int max_depth; struct pathspec_item { const char *match; int len; - int has_wildcard:1; + unsigned int has_wildcard:1; } *items; }; extern int init_pathspec(struct pathspec *, const char **); extern void free_pathspec(struct pathspec *); extern int ce_path_match(const struct cache_entry *ce, const struct pathspec *pathspec); -extern int index_fd(unsigned char *sha1, int fd, struct stat *st, int write_object, enum object_type type, const char *path); +extern int index_fd(unsigned char *sha1, int fd, struct stat *st, int write_object, enum object_type type, const char *path, int format_check); extern int index_path(unsigned char *sha1, const char *path, struct stat *st, int write_object); extern void fill_stat_cache_info(struct cache_entry *ce, struct stat *st); @@@ -526,7 -526,7 +526,7 @@@ #define REFRESH_IGNORE_MISSING 0x0008 /* ignore non-existent */ #define REFRESH_IGNORE_SUBMODULES 0x0010 /* ignore submodules */ #define REFRESH_IN_PORCELAIN 0x0020 /* user friendly output, not "needs update" */ -extern int refresh_index(struct index_state *, unsigned int flags, const char **pathspec, char *seen, char *header_msg); +extern int refresh_index(struct index_state *, unsigned int flags, const char **pathspec, char *seen, const char *header_msg); struct lock_file { struct lock_file *next; @@@ -560,6 -560,7 +560,6 @@@ extern int assume_unchanged extern int prefer_symlink_refs; extern int log_all_ref_updates; extern int warn_ambiguous_refs; -extern int unique_abbrev_extra_length; extern int shared_repository; extern const char *apply_default_whitespace; extern const char *apply_default_ignorewhitespace; @@@ -622,7 -623,7 +622,7 @@@ enum rebase_setup_type enum push_default_type { PUSH_DEFAULT_NOTHING = 0, PUSH_DEFAULT_MATCHING, - PUSH_DEFAULT_TRACKING, + PUSH_DEFAULT_UPSTREAM, PUSH_DEFAULT_CURRENT }; @@@ -690,11 -691,9 +690,11 @@@ static inline void hashclr(unsigned cha #define EMPTY_TREE_SHA1_HEX \ "4b825dc642cb6eb9a060e54bf8d69288fbee4904" -#define EMPTY_TREE_SHA1_BIN \ +#define EMPTY_TREE_SHA1_BIN_LITERAL \ "\x4b\x82\x5d\xc6\x42\xcb\x6e\xb9\xa0\x60" \ "\xe5\x4b\xf8\xd6\x92\x88\xfb\xee\x49\x04" +#define EMPTY_TREE_SHA1_BIN \ + ((const unsigned char *) EMPTY_TREE_SHA1_BIN_LITERAL) int git_mkstemp(char *path, size_t n, const char *template); @@@ -913,8 -912,7 +913,8 @@@ extern struct packed_git time_t mtime; int pack_fd; unsigned pack_local:1, - pack_keep:1; + pack_keep:1, + do_not_close:1; unsigned char sha1[20]; /* something like ".git/objects/pack/xxxxx.pack" */ char pack_name[FLEX_ARRAY]; /* more */ @@@ -1014,7 -1012,6 +1014,7 @@@ extern int git_config_maybe_bool(const extern int git_config_string(const char **, const char *, const char *); extern int git_config_pathname(const char **, const char *, const char *); extern int git_config_set(const char *, const char *); +extern int git_config_parse_key(const char *, char **, int *); extern int git_config_set_multivar(const char *, const char *, const char *, int); extern int git_config_rename_section(const char *, const char *); extern const char *git_etc_gitconfig(void);