libgit2

git_oid_streq

Version:

Check if an oid equals an hex formatted object id.

Signature

int git_oid_streq(const git_oid *id, const char *str);

Parameters

In
id

oid structure.

const char *
In
str

input hex string of an object id.

Returns

int

GIT_ENOTOID if str is not a valid hex string, 0 in case of a match, GIT_ERROR otherwise.

Versions