diff options
author | Carlos Martín Nieto <carlos@cmartin.tk> | 2012-07-23 21:56:06 +0200 |
---|---|---|
committer | Carlos Martín Nieto <carlos@cmartin.tk> | 2012-07-23 21:56:06 +0200 |
commit | 7e48635d16f68397754bf11b101e165355c34d2f (patch) | |
tree | c990e2c43cc92d1f173c16d012ff9f3818f14600 /src/revparse.c | |
parent | 8d711074ac2d1ee6a6c5f9f1e974f932cb95b42b (diff) | |
download | libgit2-7e48635d16f68397754bf11b101e165355c34d2f.tar.gz |
revparse: initialize 'parsed' in case the user doesn't give a number with the @-notation
Diffstat (limited to 'src/revparse.c')
-rw-r--r-- | src/revparse.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/revparse.c b/src/revparse.c index 650d7a904..b0469286b 100644 --- a/src/revparse.c +++ b/src/revparse.c @@ -341,7 +341,7 @@ cleanup: static int handle_at_syntax(git_object **out, git_reference **ref, const char *spec, int identifier_len, git_repository* repo, const char *curly_braces_content) { bool is_numeric; - int parsed, error = -1; + int parsed = 0, error = -1; git_buf identifier = GIT_BUF_INIT; git_time_t timestamp; |