projects
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1362671
)
builtin-grep: printf %.*s length is int, not ptrdiff_t.
author
Junio C Hamano
<junkio@cox.net>
Tue, 2 May 2006 08:28:02 +0000
(
01:28
-0700)
committer
Junio C Hamano
<junkio@cox.net>
Tue, 2 May 2006 08:28:02 +0000
(
01:28
-0700)
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-grep.c
patch
|
blob
|
history
diff --git
a/builtin-grep.c
b/builtin-grep.c
index
4be1514
..
eb821b4
100644
(file)
--- a/
builtin-grep.c
+++ b/
builtin-grep.c
@@
-103,7
+103,7
@@
static void show_line(struct grep_opt *opt, const char *bol, const char *eol,
printf("%s%c", name, sign);
if (opt->linenum)
printf("%d%c", lno, sign);
- printf("%.*s\n",
eol-bol
, bol);
+ printf("%.*s\n",
(int)(eol-bol)
, bol);
}
static int grep_buffer(struct grep_opt *opt, const char *name,