Skip to content

Commit 5f6383c

Browse files
committed
diff: ensure an unsigned number is shifted
1 parent 515683c commit 5f6383c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

include/git2/diff.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -200,18 +200,18 @@ typedef enum {
200200
/** Use the "patience diff" algorithm */
201201
GIT_DIFF_PATIENCE = (1u << 28),
202202
/** Take extra time to find minimal diff */
203-
GIT_DIFF_MINIMAL = (1 << 29),
203+
GIT_DIFF_MINIMAL = (1u << 29),
204204

205205
/** Include the necessary deflate / delta information so that `git-apply`
206206
* can apply given diff information to binary files.
207207
*/
208-
GIT_DIFF_SHOW_BINARY = (1 << 30),
208+
GIT_DIFF_SHOW_BINARY = (1u << 30),
209209

210210
/** Use a heuristic that takes indentation and whitespace into account
211211
* which generally can produce better diffs when dealing with ambiguous
212212
* diff hunks.
213213
*/
214-
GIT_DIFF_INDENT_HEURISTIC = (1 << 31),
214+
GIT_DIFF_INDENT_HEURISTIC = (1u << 31),
215215
} git_diff_option_t;
216216

217217
/**

0 commit comments

Comments
 (0)