Use 'unsigned short' for mode, like diff_filespec does
struct diff_filespec defines mode to be an 'unsigned short'. Several other places in the API which we'd like to interact with using a diff_filespec used a plain unsigned (or unsigned int). This caused problems when taking addresses, so switch to unsigned short. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
041f5ea1cf
commit
5ec1e72823
2
cache.h
2
cache.h
@ -1331,7 +1331,7 @@ static inline int hex2chr(const char *s)
|
||||
#define FALLBACK_DEFAULT_ABBREV 7
|
||||
|
||||
struct object_context {
|
||||
unsigned mode;
|
||||
unsigned short mode;
|
||||
/*
|
||||
* symlink_path is only used by get_tree_entry_follow_symlinks,
|
||||
* and only for symlinks that point outside the repository.
|
||||
|
Reference in New Issue
Block a user