From 06316234accdcb6608506aed6600cd60ff5c5c8e Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Wed, 16 Mar 2011 02:02:42 -0500 Subject: vcs-svn: remove spurious semicolons trp_gen is not a statement or function call, so it should not be followed with a semicolon. Noticed by gcc -pedantic. vcs-svn/repo_tree.c:41:81: warning: ISO C does not allow extra ';' outside of a function [-pedantic] Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- vcs-svn/repo_tree.c | 2 +- vcs-svn/string_pool.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'vcs-svn') diff --git a/vcs-svn/repo_tree.c b/vcs-svn/repo_tree.c index 491f0135a7..207ffc3a83 100644 --- a/vcs-svn/repo_tree.c +++ b/vcs-svn/repo_tree.c @@ -38,7 +38,7 @@ static uint32_t mark; static int repo_dirent_name_cmp(const void *a, const void *b); /* Treap for directory entries */ -trp_gen(static, dent_, struct repo_dirent, children, dent, repo_dirent_name_cmp); +trp_gen(static, dent_, struct repo_dirent, children, dent, repo_dirent_name_cmp) uint32_t next_blob_mark(void) { diff --git a/vcs-svn/string_pool.c b/vcs-svn/string_pool.c index f5b1da836e..8af8d54d6e 100644 --- a/vcs-svn/string_pool.c +++ b/vcs-svn/string_pool.c @@ -30,7 +30,7 @@ static int node_cmp(struct node *a, struct node *b) } /* Build a Treap from the node structure (a trp_node w/ offset) */ -trp_gen(static, tree_, struct node, children, node, node_cmp); +trp_gen(static, tree_, struct node, children, node, node_cmp) const char *pool_fetch(uint32_t entry) { -- cgit v1.2.3 From 8cc299daf29c6726acada3ffad87c3fe2098aa02 Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Sun, 27 Mar 2011 19:38:15 -0500 Subject: vcs-svn: add missing cast to printf argument gcc -m32 correctly warns: vcs-svn/fast_export.c: In function 'fast_export_commit': vcs-svn/fast_export.c:54:2: warning: format '%llu' expects argument of type 'long long unsigned int', but argument 2 has type 'unsigned int' [-Wformat] Fix it. Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- vcs-svn/fast_export.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'vcs-svn') diff --git a/vcs-svn/fast_export.c b/vcs-svn/fast_export.c index 2e5bb67255..99ed70b88a 100644 --- a/vcs-svn/fast_export.c +++ b/vcs-svn/fast_export.c @@ -51,7 +51,8 @@ void fast_export_commit(uint32_t revision, const char *author, *author ? author : "nobody", *author ? author : "nobody", *uuid ? uuid : "local", timestamp); - printf("data %"PRIuMAX"\n", log->len + strlen(gitsvnline)); + printf("data %"PRIuMAX"\n", + (uintmax_t) (log->len + strlen(gitsvnline))); fwrite(log->buf, log->len, 1, stdout); printf("%s\n", gitsvnline); if (!first_commit_done) { -- cgit v1.2.3 From 0353a0c4ec91cf2d0a8e209025aa2e1909d05f19 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Wed, 13 Apr 2011 17:39:40 +0200 Subject: remove doubled words, e.g., s/to to/to/, and fix related typos I found that some doubled words had snuck back into projects from which I'd already removed them, so now there's a "syntax-check" makefile rule in gnulib to help prevent recurrence. Running the command below spotted a few in git, too: git ls-files | xargs perl -0777 -n \ -e 'while (/\b(then?|[iao]n|i[fst]|but|f?or|at|and|[dt])\s+\1\b/gims)' \ -e '{$n=($` =~ tr/\n/\n/ + 1); ($v=$&)=~s/\n/\\n/g;' \ -e 'print "$ARGV:$n:$v\n"}' Signed-off-by: Jim Meyering Signed-off-by: Junio C Hamano --- vcs-svn/trp.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'vcs-svn') diff --git a/vcs-svn/trp.txt b/vcs-svn/trp.txt index 5ca6b42edb..177ebca335 100644 --- a/vcs-svn/trp.txt +++ b/vcs-svn/trp.txt @@ -96,7 +96,7 @@ node_type *foo_search(struct trp_root \*treap, node_type \*key):: node_type *foo_nsearch(struct trp_root \*treap, node_type \*key):: - Like `foo_search`, but if if the key is missing return what + Like `foo_search`, but if the key is missing return what would be key's successor, were key in treap (NULL if no successor). -- cgit v1.2.3