Commit 115a6c50c9c67bdf952304a3ed6a24673b42b815

Edward Thomson 2019-01-10T21:44:26

errors: remove giterr usage in fuzzers

diff --git a/fuzzers/download_refs_fuzzer.c b/fuzzers/download_refs_fuzzer.c
index 3807c09..93f1b49 100644
--- a/fuzzers/download_refs_fuzzer.c
+++ b/fuzzers/download_refs_fuzzer.c
@@ -158,7 +158,7 @@ int fuzzer_transport_cb(git_transport **out, git_remote *owner, void *param)
 
 void fuzzer_git_abort(const char *op)
 {
-	const git_error *err = giterr_last();
+	const git_error *err = git_error_last();
 	fprintf(stderr, "unexpected libgit error: %s: %s\n",
 		op, err ? err->message : "<none>");
 	abort();
diff --git a/fuzzers/packfile_fuzzer.c b/fuzzers/packfile_fuzzer.c
index e70c6c9..a448233 100644
--- a/fuzzers/packfile_fuzzer.c
+++ b/fuzzers/packfile_fuzzer.c
@@ -77,7 +77,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
 
 	if (git_indexer_new(&indexer, ".", 0, odb, NULL) < 0) {
 		fprintf(stderr, "Failed to create the indexer: %s\n",
-			giterr_last()->message);
+			git_error_last()->message);
 		abort();
 	}