git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
90639865a74d0eae4c621da68055bd9d3f79355c blob 1298 bytes (raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
 
/*
Copyright 2020 Google LLC

Use of this source code is governed by a BSD-style
license that can be found in the LICENSE file or at
https://developers.google.com/open-source/licenses/bsd
*/

#ifndef BASICS_H
#define BASICS_H

#include "system.h"

/* Bigendian en/decoding of integers */

void put_be24(uint8_t *out, uint32_t i);
uint32_t get_be24(uint8_t *in);
void put_be16(uint8_t *out, uint16_t i);

/*
  find smallest index i in [0, sz) at which f(i) is true, assuming
  that f is ascending. Return sz if f(i) is false for all indices.
*/
int binsearch(size_t sz, int (*f)(size_t k, void *args), void *args);

/*
  Frees a NULL terminated array of malloced strings. The array itself is also
  freed.
 */
void free_names(char **a);

/* parse a newline separated list of names. Empty names are discarded. */
void parse_names(char *buf, int size, char ***namesp);

/* compares two NULL-terminated arrays of strings. */
int names_equal(char **a, char **b);

/* returns the array size of a NULL-terminated array of strings. */
int names_length(char **names);

/* Allocation routines; they invoke the functions set through
 * reftable_set_alloc() */
void *reftable_malloc(size_t sz);
void *reftable_realloc(void *p, size_t sz);
void reftable_free(void *p);
void *reftable_calloc(size_t sz);

#endif
debug log:

solving 90639865a7 ...
found 90639865a7 in https://public-inbox.org/git/570a8c4bcac54295865ee0fc4514073b59725511.1600283416.git.gitgitgadget@gmail.com/ ||
	https://public-inbox.org/git/4190da597e65bce072fa3c37c9410a56def4b489.1601568663.git.gitgitgadget@gmail.com/

applying [1/2] https://public-inbox.org/git/570a8c4bcac54295865ee0fc4514073b59725511.1600283416.git.gitgitgadget@gmail.com/
diff --git a/reftable/basics.h b/reftable/basics.h
new file mode 100644
index 0000000000..90639865a7

Checking patch reftable/basics.h...
Applied patch reftable/basics.h cleanly.

skipping https://public-inbox.org/git/4190da597e65bce072fa3c37c9410a56def4b489.1601568663.git.gitgitgadget@gmail.com/ for 90639865a7
index at:
100644 90639865a74d0eae4c621da68055bd9d3f79355c	reftable/basics.h

Code repositories for project(s) associated with this inbox:

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).