]>
Commit | Line | Data |
---|---|---|
c25aa7cd PP |
1 | /* |
2 | * Copyright (C) the libgit2 contributors. All rights reserved. | |
3 | * | |
4 | * This file is part of libgit2, distributed under the GNU GPL v2 with | |
5 | * a Linking Exception. For full terms see the included COPYING file. | |
6 | */ | |
7 | #ifndef INCLUDE_threadstate_h__ | |
8 | #define INCLUDE_threadstate_h__ | |
9 | ||
10 | #include "common.h" | |
11 | ||
12 | typedef struct { | |
13 | git_error *last_error; | |
14 | git_error error_t; | |
15 | git_buf error_buf; | |
16 | char oid_fmt[GIT_OID_HEXSZ+1]; | |
17 | } git_threadstate; | |
18 | ||
19 | extern int git_threadstate_global_init(void); | |
20 | extern git_threadstate *git_threadstate_get(void); | |
21 | ||
22 | #define GIT_THREADSTATE (git_threadstate_get()) | |
23 | ||
24 | #endif |