Skip to content

Commit

Permalink
remote.c: remove useless if-before-free test
Browse files Browse the repository at this point in the history
We removed a handful of these useless if-before-free tests several months
ago.  This change removes a new one that snuck back in.

Signed-off-by: Jim Meyering <meyering@redhat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Jim Meyering authored and Junio C Hamano committed Aug 20, 2008
1 parent e9d7d10 commit c71e917
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions remote.c
Original file line number Diff line number Diff line change
Expand Up @@ -579,8 +579,7 @@ int valid_fetch_refspec(const char *fetch_refspec_str)
struct refspec *refspec;

refspec = parse_refspec_internal(1, fetch_refspec, 1, 1);
if (refspec)
free(refspec);
free(refspec);
return !!refspec;
}

Expand Down

0 comments on commit c71e917

Please sign in to comment.