libgit2

git_error_set_str

Version:

Set the error message string for this thread. This function is like git_error_set but takes a static string instead of a printf-style format.

Signature

int git_error_set_str(int error_class, const char *string);

Parameters

int
In
error_class

One of the git_error_t enum above describing the general subsystem that is responsible for the error.

const char *
In
string

The error message to keep

Returns

int

0 on success or -1 on failure

Versions