From 959f5267fa8592d75dda9a3892378c48c55eee35 Mon Sep 17 00:00:00 2001 From: Mohit Agrawal Date: Fri, 10 Nov 2017 14:47:31 +0530 Subject: dict: Fix several coverity issues in dict This patch fixes issues 230,592,593,110,63 from [1] [1] https://download.gluster.org/pub/gluster/glusterfs/static-analysis/master/glusterfs-coverity/2017-10-30-9aa574a5/html/ Note: Resolve FORWARD_NULL coverity issue in glusterfs_ctx_new is also fixed with this patch. BUG: 789278 Change-Id: Ic4199a144a14cc9ead7366fb1c9699197141bc86 Signed-off-by: Mohit Agrawal --- libglusterfs/src/dict.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libglusterfs/src/dict.h') diff --git a/libglusterfs/src/dict.h b/libglusterfs/src/dict.h index b1313636092..713da61d4ce 100644 --- a/libglusterfs/src/dict.h +++ b/libglusterfs/src/dict.h @@ -60,6 +60,8 @@ typedef struct _data_pair data_pair_t; \ } while (0) +#define DICT_KEY_VALUE_MAX_SIZE 1048576 + struct _data { unsigned char is_static:1; unsigned char is_const:1; -- cgit