blob: 53037ea6d7180408118dfb62a55d3e829e18251f [file] [log] [blame]
Brad Bishop316dfdd2018-06-25 12:45:53 -04001From efc57856f961c1f3bf016c511c53d990db8abdff Mon Sep 17 00:00:00 2001
2From: Emil Renner Berthing <systemd@esmil.dk>
3Date: Mon, 23 Oct 2017 11:31:03 -0700
4Subject: [PATCH 16/31] src/basic/missing.h: check for missing __compar_fn_t
5 typedef
6
7include missing.h for missing __compar_fn_t
8
9Upstream-Status: Pending
10
11Signed-off-by: Khem Raj <raj.khem@gmail.com>
12---
13 src/basic/missing.h | 5 +++++
14 src/basic/strbuf.c | 1 +
15 2 files changed, 6 insertions(+)
16
17diff --git a/src/basic/missing.h b/src/basic/missing.h
18index 07a8c8364..1aee3346a 100644
19--- a/src/basic/missing.h
20+++ b/src/basic/missing.h
21@@ -1162,6 +1162,11 @@ struct input_mask {
22 #define RENAME_NOREPLACE (1 << 0)
23 #endif
24
25+#ifndef __COMPAR_FN_T
26+#define __COMPAR_FN_T
27+typedef int (*__compar_fn_t)(const void *, const void *);
28+#endif
29+
30 #ifndef KCMP_FILE
31 #define KCMP_FILE 0
32 #endif
33diff --git a/src/basic/strbuf.c b/src/basic/strbuf.c
34index 8befffa66..bcb860f95 100644
35--- a/src/basic/strbuf.c
36+++ b/src/basic/strbuf.c
37@@ -24,6 +24,7 @@
38
39 #include "alloc-util.h"
40 #include "strbuf.h"
41+#include "missing.h"
42
43 /*
44 * Strbuf stores given strings in a single continuous allocated memory
45--
462.13.0
47