Skip to content

Commit

Permalink
combine-diff.c: type sanity.
Browse files Browse the repository at this point in the history
In diff_tree_combined(), show_log_first boolean is initialized with
rev->loginfo (pointer to a string); the intention is that if we have
some string to be emitted we would want to remember that fact.  Picky
compilers are offended by this, so make the expression a bit type-safer.

Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Junio C Hamano committed Jun 28, 2006
1 parent 3969cf7 commit 2c0b4df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion combine-diff.c
Original file line number Diff line number Diff line change
Expand Up @@ -841,7 +841,7 @@ void diff_tree_combined(const unsigned char *sha1,
diffopts.output_format = DIFF_FORMAT_NO_OUTPUT;
diffopts.recursive = 1;

show_log_first = rev->loginfo;
show_log_first = !!rev->loginfo;
needsep = 0;
/* find set of paths that everybody touches */
for (i = 0; i < num_parent; i++) {
Expand Down

0 comments on commit 2c0b4df

Please sign in to comment.