Skip to content

Commit fad840d

Browse files
committed
credentials: provide backcompat for opaque structs
The credential structures are now opaque and defined in `sys/credential.h`. However, we should continue to provide them for backward compatibility, unless `GIT_DEPRECATED_HARD` is set.
1 parent bba9599 commit fad840d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

include/git2/deprecated.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@
4141
*/
4242
#ifndef GIT_DEPRECATE_HARD
4343

44+
/*
45+
* The credential structures are now opaque by default, and their
46+
* definition has moved into the `sys/credential.h` header; include
47+
* them here for backward compatibility.
48+
*/
49+
#include "sys/credential.h"
50+
4451
/**
4552
* @file git2/deprecated.h
4653
* @brief libgit2 deprecated functions and values

0 commit comments

Comments
 (0)