From b77c8ddda8e68c1086227b19f9fb5db9bf89b0dc Mon Sep 17 00:00:00 2001 From: Soumya Koduri Date: Thu, 4 Jun 2015 11:25:35 +0530 Subject: Upcall/cache-invalidation: Ignore fops with frame->root->client not set Server-side internally generated fops like 'quota/marker' will not have any client associated with the frame. Hence we need a check for clients to be valid before processing for upcall cache invalidation. Also fixed an issue with initializing reaper-thread. Added a testcase to test the fix. Change-Id: If7419b98aca383f4b80711c10fef2e0b32498c57 BUG: 1227204 Signed-off-by: Soumya Koduri Reviewed-on: http://review.gluster.org/10909 Tested-by: Gluster Build System Reviewed-by: Kaleb KEITHLEY Reviewed-by: jiffin tony Thottan Tested-by: NetBSD Build System Reviewed-by: Niels de Vos --- xlators/features/upcall/src/upcall.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'xlators/features/upcall/src/upcall.c') diff --git a/xlators/features/upcall/src/upcall.c b/xlators/features/upcall/src/upcall.c index 50e621a1127..0e2a75473dc 100644 --- a/xlators/features/upcall/src/upcall.c +++ b/xlators/features/upcall/src/upcall.c @@ -1576,8 +1576,8 @@ upcall_local_wipe (xlator_t *this, upcall_local_t *local) { if (local) { inode_unref (local->inode); - mem_put (local); loc_wipe (&local->rename_oldloc); + mem_put (local); } } @@ -1629,6 +1629,7 @@ reconfigure (xlator_t *this, dict_t *options) " Disabling cache_invalidation", strerror(errno)); } + priv->reaper_init_done = 1; } out: @@ -1675,6 +1676,7 @@ init (xlator_t *this) " Disabling cache_invalidation", strerror(errno)); } + priv->reaper_init_done = 1; } out: if (ret) { -- cgit