Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/AnonR/smanonr..../opt/imh-pyth.../include/git2
File: common.h
/*
[0] Fix | Delete
* Copyright (C) the libgit2 contributors. All rights reserved.
[1] Fix | Delete
*
[2] Fix | Delete
* This file is part of libgit2, distributed under the GNU GPL v2 with
[3] Fix | Delete
* a Linking Exception. For full terms see the included COPYING file.
[4] Fix | Delete
*/
[5] Fix | Delete
#ifndef INCLUDE_git_common_h__
[6] Fix | Delete
#define INCLUDE_git_common_h__
[7] Fix | Delete
[8] Fix | Delete
#include <time.h>
[9] Fix | Delete
#include <stdlib.h>
[10] Fix | Delete
[11] Fix | Delete
#ifdef __cplusplus
[12] Fix | Delete
# define GIT_BEGIN_DECL extern "C" {
[13] Fix | Delete
# define GIT_END_DECL }
[14] Fix | Delete
#else
[15] Fix | Delete
/** Start declarations in C mode */
[16] Fix | Delete
# define GIT_BEGIN_DECL /* empty */
[17] Fix | Delete
/** End declarations in C mode */
[18] Fix | Delete
# define GIT_END_DECL /* empty */
[19] Fix | Delete
#endif
[20] Fix | Delete
[21] Fix | Delete
#if defined(_MSC_VER) && _MSC_VER < 1800
[22] Fix | Delete
# include <stdint.h>
[23] Fix | Delete
#elif !defined(__CLANG_INTTYPES_H)
[24] Fix | Delete
# include <inttypes.h>
[25] Fix | Delete
#endif
[26] Fix | Delete
[27] Fix | Delete
#ifdef DOCURIUM
[28] Fix | Delete
/*
[29] Fix | Delete
* This is so clang's doc parser acknowledges comments on functions
[30] Fix | Delete
* with size_t parameters.
[31] Fix | Delete
*/
[32] Fix | Delete
typedef size_t size_t;
[33] Fix | Delete
#endif
[34] Fix | Delete
[35] Fix | Delete
/** Declare a public function exported for application use. */
[36] Fix | Delete
#if __GNUC__ >= 4
[37] Fix | Delete
# define GIT_EXTERN(type) extern \
[38] Fix | Delete
__attribute__((visibility("default"))) \
[39] Fix | Delete
type
[40] Fix | Delete
#elif defined(_MSC_VER)
[41] Fix | Delete
# define GIT_EXTERN(type) __declspec(dllexport) type __cdecl
[42] Fix | Delete
#else
[43] Fix | Delete
# define GIT_EXTERN(type) extern type
[44] Fix | Delete
#endif
[45] Fix | Delete
[46] Fix | Delete
/** Declare a callback function for application use. */
[47] Fix | Delete
#if defined(_MSC_VER)
[48] Fix | Delete
# define GIT_CALLBACK(name) (__cdecl *name)
[49] Fix | Delete
#else
[50] Fix | Delete
# define GIT_CALLBACK(name) (*name)
[51] Fix | Delete
#endif
[52] Fix | Delete
[53] Fix | Delete
/** Declare a function as deprecated. */
[54] Fix | Delete
#if defined(__GNUC__)
[55] Fix | Delete
# define GIT_DEPRECATED(func) \
[56] Fix | Delete
__attribute__((deprecated)) \
[57] Fix | Delete
__attribute__((used)) \
[58] Fix | Delete
func
[59] Fix | Delete
#elif defined(_MSC_VER)
[60] Fix | Delete
# define GIT_DEPRECATED(func) __declspec(deprecated) func
[61] Fix | Delete
#else
[62] Fix | Delete
# define GIT_DEPRECATED(func) func
[63] Fix | Delete
#endif
[64] Fix | Delete
[65] Fix | Delete
/** Declare a function's takes printf style arguments. */
[66] Fix | Delete
#ifdef __GNUC__
[67] Fix | Delete
# define GIT_FORMAT_PRINTF(a,b) __attribute__((format (printf, a, b)))
[68] Fix | Delete
#else
[69] Fix | Delete
# define GIT_FORMAT_PRINTF(a,b) /* empty */
[70] Fix | Delete
#endif
[71] Fix | Delete
[72] Fix | Delete
#if (defined(_WIN32)) && !defined(__CYGWIN__)
[73] Fix | Delete
#define GIT_WIN32 1
[74] Fix | Delete
#endif
[75] Fix | Delete
[76] Fix | Delete
#ifdef __amigaos4__
[77] Fix | Delete
#include <netinet/in.h>
[78] Fix | Delete
#endif
[79] Fix | Delete
[80] Fix | Delete
/**
[81] Fix | Delete
* @file git2/common.h
[82] Fix | Delete
* @brief Git common platform definitions
[83] Fix | Delete
* @defgroup git_common Git common platform definitions
[84] Fix | Delete
* @ingroup Git
[85] Fix | Delete
* @{
[86] Fix | Delete
*/
[87] Fix | Delete
[88] Fix | Delete
GIT_BEGIN_DECL
[89] Fix | Delete
[90] Fix | Delete
/**
[91] Fix | Delete
* The separator used in path list strings (ie like in the PATH
[92] Fix | Delete
* environment variable). A semi-colon ";" is used on Windows, and
[93] Fix | Delete
* a colon ":" for all other systems.
[94] Fix | Delete
*/
[95] Fix | Delete
#ifdef GIT_WIN32
[96] Fix | Delete
#define GIT_PATH_LIST_SEPARATOR ';'
[97] Fix | Delete
#else
[98] Fix | Delete
#define GIT_PATH_LIST_SEPARATOR ':'
[99] Fix | Delete
#endif
[100] Fix | Delete
[101] Fix | Delete
/**
[102] Fix | Delete
* The maximum length of a valid git path.
[103] Fix | Delete
*/
[104] Fix | Delete
#define GIT_PATH_MAX 4096
[105] Fix | Delete
[106] Fix | Delete
/**
[107] Fix | Delete
* The string representation of the null object ID.
[108] Fix | Delete
*/
[109] Fix | Delete
#define GIT_OID_HEX_ZERO "0000000000000000000000000000000000000000"
[110] Fix | Delete
[111] Fix | Delete
/**
[112] Fix | Delete
* Return the version of the libgit2 library
[113] Fix | Delete
* being currently used.
[114] Fix | Delete
*
[115] Fix | Delete
* @param major Store the major version number
[116] Fix | Delete
* @param minor Store the minor version number
[117] Fix | Delete
* @param rev Store the revision (patch) number
[118] Fix | Delete
* @return 0 on success or an error code on failure
[119] Fix | Delete
*/
[120] Fix | Delete
GIT_EXTERN(int) git_libgit2_version(int *major, int *minor, int *rev);
[121] Fix | Delete
[122] Fix | Delete
/**
[123] Fix | Delete
* Combinations of these values describe the features with which libgit2
[124] Fix | Delete
* was compiled
[125] Fix | Delete
*/
[126] Fix | Delete
typedef enum {
[127] Fix | Delete
/**
[128] Fix | Delete
* If set, libgit2 was built thread-aware and can be safely used from multiple
[129] Fix | Delete
* threads.
[130] Fix | Delete
*/
[131] Fix | Delete
GIT_FEATURE_THREADS = (1 << 0),
[132] Fix | Delete
/**
[133] Fix | Delete
* If set, libgit2 was built with and linked against a TLS implementation.
[134] Fix | Delete
* Custom TLS streams may still be added by the user to support HTTPS
[135] Fix | Delete
* regardless of this.
[136] Fix | Delete
*/
[137] Fix | Delete
GIT_FEATURE_HTTPS = (1 << 1),
[138] Fix | Delete
/**
[139] Fix | Delete
* If set, libgit2 was built with and linked against libssh2. A custom
[140] Fix | Delete
* transport may still be added by the user to support libssh2 regardless of
[141] Fix | Delete
* this.
[142] Fix | Delete
*/
[143] Fix | Delete
GIT_FEATURE_SSH = (1 << 2),
[144] Fix | Delete
/**
[145] Fix | Delete
* If set, libgit2 was built with support for sub-second resolution in file
[146] Fix | Delete
* modification times.
[147] Fix | Delete
*/
[148] Fix | Delete
GIT_FEATURE_NSEC = (1 << 3),
[149] Fix | Delete
} git_feature_t;
[150] Fix | Delete
[151] Fix | Delete
/**
[152] Fix | Delete
* Query compile time options for libgit2.
[153] Fix | Delete
*
[154] Fix | Delete
* @return A combination of GIT_FEATURE_* values.
[155] Fix | Delete
*
[156] Fix | Delete
* - GIT_FEATURE_THREADS
[157] Fix | Delete
* Libgit2 was compiled with thread support. Note that thread support is
[158] Fix | Delete
* still to be seen as a 'work in progress' - basic object lookups are
[159] Fix | Delete
* believed to be threadsafe, but other operations may not be.
[160] Fix | Delete
*
[161] Fix | Delete
* - GIT_FEATURE_HTTPS
[162] Fix | Delete
* Libgit2 supports the https:// protocol. This requires the openssl
[163] Fix | Delete
* library to be found when compiling libgit2.
[164] Fix | Delete
*
[165] Fix | Delete
* - GIT_FEATURE_SSH
[166] Fix | Delete
* Libgit2 supports the SSH protocol for network operations. This requires
[167] Fix | Delete
* the libssh2 library to be found when compiling libgit2
[168] Fix | Delete
*/
[169] Fix | Delete
GIT_EXTERN(int) git_libgit2_features(void);
[170] Fix | Delete
[171] Fix | Delete
/**
[172] Fix | Delete
* Global library options
[173] Fix | Delete
*
[174] Fix | Delete
* These are used to select which global option to set or get and are
[175] Fix | Delete
* used in `git_libgit2_opts()`.
[176] Fix | Delete
*/
[177] Fix | Delete
typedef enum {
[178] Fix | Delete
GIT_OPT_GET_MWINDOW_SIZE,
[179] Fix | Delete
GIT_OPT_SET_MWINDOW_SIZE,
[180] Fix | Delete
GIT_OPT_GET_MWINDOW_MAPPED_LIMIT,
[181] Fix | Delete
GIT_OPT_SET_MWINDOW_MAPPED_LIMIT,
[182] Fix | Delete
GIT_OPT_GET_SEARCH_PATH,
[183] Fix | Delete
GIT_OPT_SET_SEARCH_PATH,
[184] Fix | Delete
GIT_OPT_SET_CACHE_OBJECT_LIMIT,
[185] Fix | Delete
GIT_OPT_SET_CACHE_MAX_SIZE,
[186] Fix | Delete
GIT_OPT_ENABLE_CACHING,
[187] Fix | Delete
GIT_OPT_GET_CACHED_MEMORY,
[188] Fix | Delete
GIT_OPT_GET_TEMPLATE_PATH,
[189] Fix | Delete
GIT_OPT_SET_TEMPLATE_PATH,
[190] Fix | Delete
GIT_OPT_SET_SSL_CERT_LOCATIONS,
[191] Fix | Delete
GIT_OPT_SET_USER_AGENT,
[192] Fix | Delete
GIT_OPT_ENABLE_STRICT_OBJECT_CREATION,
[193] Fix | Delete
GIT_OPT_ENABLE_STRICT_SYMBOLIC_REF_CREATION,
[194] Fix | Delete
GIT_OPT_SET_SSL_CIPHERS,
[195] Fix | Delete
GIT_OPT_GET_USER_AGENT,
[196] Fix | Delete
GIT_OPT_ENABLE_OFS_DELTA,
[197] Fix | Delete
GIT_OPT_ENABLE_FSYNC_GITDIR,
[198] Fix | Delete
GIT_OPT_GET_WINDOWS_SHAREMODE,
[199] Fix | Delete
GIT_OPT_SET_WINDOWS_SHAREMODE,
[200] Fix | Delete
GIT_OPT_ENABLE_STRICT_HASH_VERIFICATION,
[201] Fix | Delete
GIT_OPT_SET_ALLOCATOR,
[202] Fix | Delete
GIT_OPT_ENABLE_UNSAVED_INDEX_SAFETY,
[203] Fix | Delete
GIT_OPT_GET_PACK_MAX_OBJECTS,
[204] Fix | Delete
GIT_OPT_SET_PACK_MAX_OBJECTS,
[205] Fix | Delete
GIT_OPT_DISABLE_PACK_KEEP_FILE_CHECKS,
[206] Fix | Delete
GIT_OPT_ENABLE_HTTP_EXPECT_CONTINUE,
[207] Fix | Delete
GIT_OPT_GET_MWINDOW_FILE_LIMIT,
[208] Fix | Delete
GIT_OPT_SET_MWINDOW_FILE_LIMIT
[209] Fix | Delete
} git_libgit2_opt_t;
[210] Fix | Delete
[211] Fix | Delete
/**
[212] Fix | Delete
* Set or query a library global option
[213] Fix | Delete
*
[214] Fix | Delete
* Available options:
[215] Fix | Delete
*
[216] Fix | Delete
* * opts(GIT_OPT_GET_MWINDOW_SIZE, size_t *):
[217] Fix | Delete
*
[218] Fix | Delete
* > Get the maximum mmap window size
[219] Fix | Delete
*
[220] Fix | Delete
* * opts(GIT_OPT_SET_MWINDOW_SIZE, size_t):
[221] Fix | Delete
*
[222] Fix | Delete
* > Set the maximum mmap window size
[223] Fix | Delete
*
[224] Fix | Delete
* * opts(GIT_OPT_GET_MWINDOW_MAPPED_LIMIT, size_t *):
[225] Fix | Delete
*
[226] Fix | Delete
* > Get the maximum memory that will be mapped in total by the library
[227] Fix | Delete
*
[228] Fix | Delete
* * opts(GIT_OPT_SET_MWINDOW_MAPPED_LIMIT, size_t):
[229] Fix | Delete
*
[230] Fix | Delete
* > Set the maximum amount of memory that can be mapped at any time
[231] Fix | Delete
* > by the library
[232] Fix | Delete
*
[233] Fix | Delete
* * opts(GIT_OPT_GET_MWINDOW_FILE_LIMIT, size_t *):
[234] Fix | Delete
*
[235] Fix | Delete
* > Get the maximum number of files that will be mapped at any time by the
[236] Fix | Delete
* > library
[237] Fix | Delete
*
[238] Fix | Delete
* * opts(GIT_OPT_SET_MWINDOW_FILE_LIMIT, size_t):
[239] Fix | Delete
*
[240] Fix | Delete
* > Set the maximum number of files that can be mapped at any time
[241] Fix | Delete
* > by the library. The default (0) is unlimited.
[242] Fix | Delete
*
[243] Fix | Delete
* * opts(GIT_OPT_GET_SEARCH_PATH, int level, git_buf *buf)
[244] Fix | Delete
*
[245] Fix | Delete
* > Get the search path for a given level of config data. "level" must
[246] Fix | Delete
* > be one of `GIT_CONFIG_LEVEL_SYSTEM`, `GIT_CONFIG_LEVEL_GLOBAL`,
[247] Fix | Delete
* > `GIT_CONFIG_LEVEL_XDG`, or `GIT_CONFIG_LEVEL_PROGRAMDATA`.
[248] Fix | Delete
* > The search path is written to the `out` buffer.
[249] Fix | Delete
*
[250] Fix | Delete
* * opts(GIT_OPT_SET_SEARCH_PATH, int level, const char *path)
[251] Fix | Delete
*
[252] Fix | Delete
* > Set the search path for a level of config data. The search path
[253] Fix | Delete
* > applied to shared attributes and ignore files, too.
[254] Fix | Delete
* >
[255] Fix | Delete
* > - `path` lists directories delimited by GIT_PATH_LIST_SEPARATOR.
[256] Fix | Delete
* > Pass NULL to reset to the default (generally based on environment
[257] Fix | Delete
* > variables). Use magic path `$PATH` to include the old value
[258] Fix | Delete
* > of the path (if you want to prepend or append, for instance).
[259] Fix | Delete
* >
[260] Fix | Delete
* > - `level` must be `GIT_CONFIG_LEVEL_SYSTEM`,
[261] Fix | Delete
* > `GIT_CONFIG_LEVEL_GLOBAL`, `GIT_CONFIG_LEVEL_XDG`, or
[262] Fix | Delete
* > `GIT_CONFIG_LEVEL_PROGRAMDATA`.
[263] Fix | Delete
*
[264] Fix | Delete
* * opts(GIT_OPT_SET_CACHE_OBJECT_LIMIT, git_object_t type, size_t size)
[265] Fix | Delete
*
[266] Fix | Delete
* > Set the maximum data size for the given type of object to be
[267] Fix | Delete
* > considered eligible for caching in memory. Setting to value to
[268] Fix | Delete
* > zero means that that type of object will not be cached.
[269] Fix | Delete
* > Defaults to 0 for GIT_OBJECT_BLOB (i.e. won't cache blobs) and 4k
[270] Fix | Delete
* > for GIT_OBJECT_COMMIT, GIT_OBJECT_TREE, and GIT_OBJECT_TAG.
[271] Fix | Delete
*
[272] Fix | Delete
* * opts(GIT_OPT_SET_CACHE_MAX_SIZE, ssize_t max_storage_bytes)
[273] Fix | Delete
*
[274] Fix | Delete
* > Set the maximum total data size that will be cached in memory
[275] Fix | Delete
* > across all repositories before libgit2 starts evicting objects
[276] Fix | Delete
* > from the cache. This is a soft limit, in that the library might
[277] Fix | Delete
* > briefly exceed it, but will start aggressively evicting objects
[278] Fix | Delete
* > from cache when that happens. The default cache size is 256MB.
[279] Fix | Delete
*
[280] Fix | Delete
* * opts(GIT_OPT_ENABLE_CACHING, int enabled)
[281] Fix | Delete
*
[282] Fix | Delete
* > Enable or disable caching completely.
[283] Fix | Delete
* >
[284] Fix | Delete
* > Because caches are repository-specific, disabling the cache
[285] Fix | Delete
* > cannot immediately clear all cached objects, but each cache will
[286] Fix | Delete
* > be cleared on the next attempt to update anything in it.
[287] Fix | Delete
*
[288] Fix | Delete
* * opts(GIT_OPT_GET_CACHED_MEMORY, ssize_t *current, ssize_t *allowed)
[289] Fix | Delete
*
[290] Fix | Delete
* > Get the current bytes in cache and the maximum that would be
[291] Fix | Delete
* > allowed in the cache.
[292] Fix | Delete
*
[293] Fix | Delete
* * opts(GIT_OPT_GET_TEMPLATE_PATH, git_buf *out)
[294] Fix | Delete
*
[295] Fix | Delete
* > Get the default template path.
[296] Fix | Delete
* > The path is written to the `out` buffer.
[297] Fix | Delete
*
[298] Fix | Delete
* * opts(GIT_OPT_SET_TEMPLATE_PATH, const char *path)
[299] Fix | Delete
*
[300] Fix | Delete
* > Set the default template path.
[301] Fix | Delete
* >
[302] Fix | Delete
* > - `path` directory of template.
[303] Fix | Delete
*
[304] Fix | Delete
* * opts(GIT_OPT_SET_SSL_CERT_LOCATIONS, const char *file, const char *path)
[305] Fix | Delete
*
[306] Fix | Delete
* > Set the SSL certificate-authority locations.
[307] Fix | Delete
* >
[308] Fix | Delete
* > - `file` is the location of a file containing several
[309] Fix | Delete
* > certificates concatenated together.
[310] Fix | Delete
* > - `path` is the location of a directory holding several
[311] Fix | Delete
* > certificates, one per file.
[312] Fix | Delete
* >
[313] Fix | Delete
* > Either parameter may be `NULL`, but not both.
[314] Fix | Delete
*
[315] Fix | Delete
* * opts(GIT_OPT_SET_USER_AGENT, const char *user_agent)
[316] Fix | Delete
*
[317] Fix | Delete
* > Set the value of the User-Agent header. This value will be
[318] Fix | Delete
* > appended to "git/1.0", for compatibility with other git clients.
[319] Fix | Delete
* >
[320] Fix | Delete
* > - `user_agent` is the value that will be delivered as the
[321] Fix | Delete
* > User-Agent header on HTTP requests.
[322] Fix | Delete
*
[323] Fix | Delete
* * opts(GIT_OPT_SET_WINDOWS_SHAREMODE, unsigned long value)
[324] Fix | Delete
*
[325] Fix | Delete
* > Set the share mode used when opening files on Windows.
[326] Fix | Delete
* > For more information, see the documentation for CreateFile.
[327] Fix | Delete
* > The default is: FILE_SHARE_READ | FILE_SHARE_WRITE. This is
[328] Fix | Delete
* > ignored and unused on non-Windows platforms.
[329] Fix | Delete
*
[330] Fix | Delete
* * opts(GIT_OPT_GET_WINDOWS_SHAREMODE, unsigned long *value)
[331] Fix | Delete
*
[332] Fix | Delete
* > Get the share mode used when opening files on Windows.
[333] Fix | Delete
*
[334] Fix | Delete
* * opts(GIT_OPT_ENABLE_STRICT_OBJECT_CREATION, int enabled)
[335] Fix | Delete
*
[336] Fix | Delete
* > Enable strict input validation when creating new objects
[337] Fix | Delete
* > to ensure that all inputs to the new objects are valid. For
[338] Fix | Delete
* > example, when this is enabled, the parent(s) and tree inputs
[339] Fix | Delete
* > will be validated when creating a new commit. This defaults
[340] Fix | Delete
* > to enabled.
[341] Fix | Delete
*
[342] Fix | Delete
* * opts(GIT_OPT_ENABLE_STRICT_SYMBOLIC_REF_CREATION, int enabled)
[343] Fix | Delete
*
[344] Fix | Delete
* > Validate the target of a symbolic ref when creating it. For
[345] Fix | Delete
* > example, `foobar` is not a valid ref, therefore `foobar` is
[346] Fix | Delete
* > not a valid target for a symbolic ref by default, whereas
[347] Fix | Delete
* > `refs/heads/foobar` is. Disabling this bypasses validation
[348] Fix | Delete
* > so that an arbitrary strings such as `foobar` can be used
[349] Fix | Delete
* > for a symbolic ref target. This defaults to enabled.
[350] Fix | Delete
*
[351] Fix | Delete
* * opts(GIT_OPT_SET_SSL_CIPHERS, const char *ciphers)
[352] Fix | Delete
*
[353] Fix | Delete
* > Set the SSL ciphers use for HTTPS connections.
[354] Fix | Delete
* >
[355] Fix | Delete
* > - `ciphers` is the list of ciphers that are eanbled.
[356] Fix | Delete
*
[357] Fix | Delete
* * opts(GIT_OPT_ENABLE_OFS_DELTA, int enabled)
[358] Fix | Delete
*
[359] Fix | Delete
* > Enable or disable the use of "offset deltas" when creating packfiles,
[360] Fix | Delete
* > and the negotiation of them when talking to a remote server.
[361] Fix | Delete
* > Offset deltas store a delta base location as an offset into the
[362] Fix | Delete
* > packfile from the current location, which provides a shorter encoding
[363] Fix | Delete
* > and thus smaller resultant packfiles.
[364] Fix | Delete
* > Packfiles containing offset deltas can still be read.
[365] Fix | Delete
* > This defaults to enabled.
[366] Fix | Delete
*
[367] Fix | Delete
* * opts(GIT_OPT_ENABLE_FSYNC_GITDIR, int enabled)
[368] Fix | Delete
*
[369] Fix | Delete
* > Enable synchronized writes of files in the gitdir using `fsync`
[370] Fix | Delete
* > (or the platform equivalent) to ensure that new object data
[371] Fix | Delete
* > is written to permanent storage, not simply cached. This
[372] Fix | Delete
* > defaults to disabled.
[373] Fix | Delete
*
[374] Fix | Delete
* opts(GIT_OPT_ENABLE_STRICT_HASH_VERIFICATION, int enabled)
[375] Fix | Delete
*
[376] Fix | Delete
* > Enable strict verification of object hashsums when reading
[377] Fix | Delete
* > objects from disk. This may impact performance due to an
[378] Fix | Delete
* > additional checksum calculation on each object. This defaults
[379] Fix | Delete
* > to enabled.
[380] Fix | Delete
*
[381] Fix | Delete
* opts(GIT_OPT_SET_ALLOCATOR, git_allocator *allocator)
[382] Fix | Delete
*
[383] Fix | Delete
* > Set the memory allocator to a different memory allocator. This
[384] Fix | Delete
* > allocator will then be used to make all memory allocations for
[385] Fix | Delete
* > libgit2 operations. If the given `allocator` is NULL, then the
[386] Fix | Delete
* > system default will be restored.
[387] Fix | Delete
*
[388] Fix | Delete
* opts(GIT_OPT_ENABLE_UNSAVED_INDEX_SAFETY, int enabled)
[389] Fix | Delete
*
[390] Fix | Delete
* > Ensure that there are no unsaved changes in the index before
[391] Fix | Delete
* > beginning any operation that reloads the index from disk (eg,
[392] Fix | Delete
* > checkout). If there are unsaved changes, the instruction will
[393] Fix | Delete
* > fail. (Using the FORCE flag to checkout will still overwrite
[394] Fix | Delete
* > these changes.)
[395] Fix | Delete
*
[396] Fix | Delete
* opts(GIT_OPT_GET_PACK_MAX_OBJECTS, size_t *out)
[397] Fix | Delete
*
[398] Fix | Delete
* > Get the maximum number of objects libgit2 will allow in a pack
[399] Fix | Delete
* > file when downloading a pack file from a remote. This can be
[400] Fix | Delete
* > used to limit maximum memory usage when fetching from an untrusted
[401] Fix | Delete
* > remote.
[402] Fix | Delete
*
[403] Fix | Delete
* opts(GIT_OPT_SET_PACK_MAX_OBJECTS, size_t objects)
[404] Fix | Delete
*
[405] Fix | Delete
* > Set the maximum number of objects libgit2 will allow in a pack
[406] Fix | Delete
* > file when downloading a pack file from a remote.
[407] Fix | Delete
*
[408] Fix | Delete
* opts(GIT_OPT_DISABLE_PACK_KEEP_FILE_CHECKS, int enabled)
[409] Fix | Delete
* > This will cause .keep file existence checks to be skipped when
[410] Fix | Delete
* > accessing packfiles, which can help performance with remote filesystems.
[411] Fix | Delete
*
[412] Fix | Delete
* opts(GIT_OPT_ENABLE_HTTP_EXPECT_CONTINUE, int enabled)
[413] Fix | Delete
* > When connecting to a server using NTLM or Negotiate
[414] Fix | Delete
* > authentication, use expect/continue when POSTing data.
[415] Fix | Delete
* > This option is not available on Windows.
[416] Fix | Delete
*
[417] Fix | Delete
* @param option Option key
[418] Fix | Delete
* @param ... value to set the option
[419] Fix | Delete
* @return 0 on success, <0 on failure
[420] Fix | Delete
*/
[421] Fix | Delete
GIT_EXTERN(int) git_libgit2_opts(int option, ...);
[422] Fix | Delete
[423] Fix | Delete
/** @} */
[424] Fix | Delete
GIT_END_DECL
[425] Fix | Delete
[426] Fix | Delete
#endif
[427] Fix | Delete
[428] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function