]>
Commit | Line | Data |
---|---|---|
a15c550d | 1 | /* |
359fc2d2 | 2 | * Copyright (C) the libgit2 contributors. All rights reserved. |
a15c550d VM |
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_global_h__ | |
8 | #define INCLUDE_global_h__ | |
9 | ||
3b2cb2c9 | 10 | #include "common.h" |
a15c550d | 11 | #include "mwindow.h" |
d6fb0924 | 12 | #include "hash.h" |
a15c550d VM |
13 | |
14 | typedef struct { | |
1a481123 VM |
15 | git_error *last_error; |
16 | git_error error_t; | |
3b2cb2c9 | 17 | char oid_fmt[GIT_OID_HEXSZ+1]; |
a15c550d VM |
18 | } git_global_st; |
19 | ||
24e53d2f | 20 | #ifdef GIT_OPENSSL |
cf15ac8a CMN |
21 | # include <openssl/ssl.h> |
22 | extern SSL_CTX *git__ssl_ctx; | |
23 | #endif | |
24 | ||
a15c550d VM |
25 | git_global_st *git__global_state(void); |
26 | ||
8cef828d CMN |
27 | extern git_mutex git__mwindow_mutex; |
28 | ||
a15c550d VM |
29 | #define GIT_GLOBAL (git__global_state()) |
30 | ||
a3aa5f4d RB |
31 | typedef void (*git_global_shutdown_fn)(void); |
32 | ||
33 | extern void git__on_shutdown(git_global_shutdown_fn callback); | |
34 | ||
06c985d8 | 35 | extern void git__free_tls_data(void); |
55c5f756 | 36 | |
a15c550d | 37 | #endif |