Fix memory leak in git2r_reference_list

* src/git2r_reference.c (git2r_reference_list): Free allocated memory
  for git_reference from git_reference_lookup.

Signed-off-by: Stefan Widgren <stefan.widgren@gmail.com>