* a Linking Exception. For full terms see the included COPYING file.
*/
-#include <assert.h>
-#include <dirent.h>
#include <stdio.h>
-#include <stdlib.h>
-#include <sys/types.h>
#include "git2.h"
-#include "fileops.h"
+#include "futils.h"
#include "path.h"
extern int LLVMFuzzerTestOneInput(const unsigned char *data, size_t size);
int error = 0;
if (git_futils_readbuffer(&buf, filename) < 0) {
- fprintf(stderr, "Failed to read %s: %m\n", filename);
+ fprintf(stderr, "Failed to read %s: %s\n", filename, git_error_last()->message);
error = -1;
goto exit;
}
LLVMFuzzerInitialize(&argc, &argv);
if (git_path_dirload(&corpus_files, argv[1], 0, 0x0) < 0) {
- fprintf(stderr, "Failed to scan corpus directory: %m\n");
+ fprintf(stderr, "Failed to scan corpus directory '%s': %s\n",
+ argv[1], git_error_last()->message);
error = -1;
goto exit;
}