summaryrefslogtreecommitdiffstats
path: root/patches/libmemcache-1.4.0.rc2/0004-remove-broken-inline.patch
blob: 778207b6699a61d9f455256626d1c4a1178e9174 (plain)
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
From: Michael Olbrich <m.olbrich@pengutronix.de>
Date: Thu, 22 Dec 2011 10:30:24 +0100
Subject: [PATCH] remove broken inline

Without this we may get something like this:

[...]/libmemcache.so: undefined reference to `mcm_buf_len'
[...]/libmemcache.so: undefined reference to `mcm_buf_remain_off'

Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
---
 include/memcache/buffer.h | 6 +++---
 src/buffer.c              | 6 +++---
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/include/memcache/buffer.h b/include/memcache/buffer.h
index 2205b23..d352377 100644
--- a/include/memcache/buffer.h
+++ b/include/memcache/buffer.h
@@ -63,14 +63,14 @@ struct memcache_buf	*mcm_buf_find_replace(struct memcache_ctxt *, struct memcach
 struct memcache_buf	*mcm_buf_find_replace2(struct memcache_ctxt *, struct memcache_buf *,
 						    const char *, struct memcache_buf *);
 int	 mcm_buf_free(struct memcache_ctxt *, struct memcache_buf **);
-inline u_int32_t	 mcm_buf_len(const struct memcache_ctxt *, const struct memcache_buf *);
+u_int32_t	 mcm_buf_len(const struct memcache_ctxt *, const struct memcache_buf *);
 struct memcache_buf	*mcm_buf_new(struct memcache_ctxt *);
 struct memcache_buf	*mcm_buf_new2(struct memcache_ctxt *, const char *, const u_int32_t);
 struct memcache_buf	*mcm_buf_new3(struct memcache_ctxt *, const char *);
 size_t	 mcm_buf_read(struct memcache_ctxt *, struct memcache_buf *, int);
 int	 mcm_buf_realloc(struct memcache_ctxt *, struct memcache_buf *, const u_int32_t);
-inline size_t	 mcm_buf_remain(const struct memcache_ctxt *, const struct memcache_buf *);
-inline size_t	 mcm_buf_remain_off(const struct memcache_ctxt *, const struct memcache_buf *);
+size_t	 mcm_buf_remain(const struct memcache_ctxt *, const struct memcache_buf *);
+size_t	 mcm_buf_remain_off(const struct memcache_ctxt *, const struct memcache_buf *);
 int	 mcm_buf_replace(struct memcache_ctxt *, struct memcache_buf *, const char *, const u_int32_t);
 int	 mcm_buf_replace2(struct memcache_ctxt *, struct memcache_buf *, const char *);
 int	 mcm_buf_replace_buf(struct memcache_ctxt *, struct memcache_buf *, struct memcache_buf *);
diff --git a/src/buffer.c b/src/buffer.c
index 616307f..3934a7d 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -259,7 +259,7 @@ mcm_buf_free(struct memcache_ctxt *ctxt, struct memcache_buf **buf) {
 }
 
 
-inline u_int32_t
+u_int32_t
 mcm_buf_len(const struct memcache_ctxt *ctxt, const struct memcache_buf *s) {
   return s->len;
 }
@@ -425,13 +425,13 @@ mcm_buf_realloc(struct memcache_ctxt *ctxt, struct memcache_buf *buf, const u_in
 }
 
 
-inline size_t
+size_t
 mcm_buf_remain(const struct memcache_ctxt *ctxt, const struct memcache_buf *buf) {
   return mcm_buf_size(ctxt, buf) - mcm_buf_len(ctxt, buf);
 }
 
 
-inline size_t
+size_t
 mcm_buf_remain_off(const struct memcache_ctxt *ctxt, const struct memcache_buf *buf) {
   return mcm_buf_len(ctxt, buf) - buf->off;
 }