summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/glusterfs/glusterfs.h
diff options
context:
space:
mode:
authorPoornima G <pgurusid@redhat.com>2018-11-21 10:01:08 +0530
committerAmar Tumballi <amarts@redhat.com>2018-12-17 17:26:59 +0000
commit9ff080382cb8c8aab561f4131c3f631e33670338 (patch)
tree5a18a0e6715f86a87429a92e25dee400f18f97bb /libglusterfs/src/glusterfs/glusterfs.h
parent822779332e193471a6caa3199f0f618d2aa2c900 (diff)
mem-pool: Add api to mem_get based on requested size
Currently mem-pool implementation provides api to get from the mem pool based on the struct type. This is to retain api compatibility with the old implementation of mem pool. Internally in the mem pool structure there is a mapping from struct to size based pools. In this patch, we are adding new APIs to fetch memory from mem pool, given a size. Change-Id: Ib220ee45ebd134a7be8f6482db5a592dbb7b9211 Updates: #325 Signed-off-by: Poornima G <pgurusid@redhat.com>
Diffstat (limited to 'libglusterfs/src/glusterfs/glusterfs.h')
-rw-r--r--libglusterfs/src/glusterfs/glusterfs.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/libglusterfs/src/glusterfs/glusterfs.h b/libglusterfs/src/glusterfs/glusterfs.h
index 9f14f2f5440..325241818c0 100644
--- a/libglusterfs/src/glusterfs/glusterfs.h
+++ b/libglusterfs/src/glusterfs/glusterfs.h
@@ -14,6 +14,7 @@
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
+#include <stdbool.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/types.h>
@@ -369,6 +370,10 @@ enum gf_internal_fop_indicator {
#define GF_CS_OBJECT_STATUS "trusted.glusterfs.cs.status"
#define GF_CS_OBJECT_REPAIR "trusted.glusterfs.cs.repair"
+#define gf_boolean_t bool
+#define _gf_false false
+#define _gf_true true
+
typedef enum {
GF_CS_LOCAL = 1,
GF_CS_REMOTE = 2,