threads / patch / 48593

patchcommit-graph: fix a sparse 'integer as NULL pointer' warning

Subject: [PATCH] commit-graph: fix a sparse 'integer as NULL pointer' warning

## tl;dr

2 messages between May 29, 2018 and May 30, 2018. Diffs are folded; open one to read it.

replies: 1people: 2as markdown or json

Ramsay Jones· May 29, 2018, 20:01 UTC · lore
Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
---
Hi Derrick,

If you need to re-roll your 'ds/commit-graph-fsck' branch (pu@a84e06bc0f), could you please squash this into the relevant patch (commit 80453b4529, "commit-graph: add 'verify' subcommand", 2018-05-24).

[No, No, that was the one in graph_read(). :-D ]
Thanks!

ATB, Ramsay Jones

 builtin/commit-graph.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Show changes to builtin/commit-graph.c +1 −1
diff --git a/builtin/commit-graph.c b/builtin/commit-graph.c
index 20ce6437a..6abfde5e6 100644
--- a/builtin/commit-graph.c
+++ b/builtin/commit-graph.c
@@ -39,7 +39,7 @@ static struct opts_commit_graph {
 
 static int graph_verify(int argc, const char **argv)
 {
-	struct commit_graph *graph = 0;
+	struct commit_graph *graph = NULL;
 	char *graph_name;
 
 	static struct option builtin_commit_graph_verify_options[] = {
-- 
2.17.0
Derrick Stolee· May 30, 2018, 00:57 UTC · re: Ramsay Jones · lore

Re: [PATCH] commit-graph: fix a sparse 'integer as NULL pointer' warning

n 5/29/2018 4:01 PM, Ramsay Jones wrote:
Show 10 quoted lines
> Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
> ---
>
> Hi Derrick,
>
> If you need to re-roll your 'ds/commit-graph-fsck' branch (pu@a84e06bc0f),
> could you please squash this into the relevant patch (commit 80453b4529,
> "commit-graph: add 'verify' subcommand", 2018-05-24).
>
> [No, No, that was the one in graph_read(). :-D ]
Thanks for helping rid me of my bad habits! I'll get this one in v4.
Show 22 quoted lines
>
> Thanks!
>
> ATB,
> Ramsay Jones
>
>   builtin/commit-graph.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/builtin/commit-graph.c b/builtin/commit-graph.c
> index 20ce6437a..6abfde5e6 100644
> --- a/builtin/commit-graph.c
> +++ b/builtin/commit-graph.c
> @@ -39,7 +39,7 @@ static struct opts_commit_graph {
>   
>   static int graph_verify(int argc, const char **argv)
>   {
> -	struct commit_graph *graph = 0;
> +	struct commit_graph *graph = NULL;
>   	char *graph_name;
>   
>   	static struct option builtin_commit_graph_verify_options[] = {

← back to recent threads