mirror of
https://git.proxmox.com/git/libgit2
synced 2025-06-24 17:51:17 +00:00
Use new error handling in the example network code
This commit is contained in:
parent
bd6585a7f5
commit
fc1cc2051e
@ -31,7 +31,7 @@ int run_command(git_cb fn, int argc, char **argv)
|
||||
// Run the command. If something goes wrong, print the error message to stderr
|
||||
error = fn(repo, argc, argv);
|
||||
if (error < GIT_SUCCESS)
|
||||
fprintf(stderr, "Bad news:\n %s\n", git_lasterror());
|
||||
fprintf(stderr, "Bad news:\n %s\n", git_error_last()->message);
|
||||
|
||||
if(repo)
|
||||
git_repository_free(repo);
|
||||
|
Loading…
Reference in New Issue
Block a user