diff options
author | Mohammed Rafi KC <rkavunga@redhat.com> | 2015-06-30 11:22:31 +0530 |
---|---|---|
committer | Dan Lambright <dlambrig@redhat.com> | 2015-07-12 20:28:18 -0700 |
commit | 2e44d1580497eb75f325ad3104249a425ddf592a (patch) | |
tree | a9821f9a8743207ddcfd39c344923bb398b1564e /xlators/features/changetimerecorder/src/ctr-helper.h | |
parent | d5246b38e68e80136bfc2a1c570189537b9de1ce (diff) |
ctr:Avoid assertion failure in lookup
in ctr_lookup, the loc variable need not be comes with pargfid,
though there is a parent for the inode. The same for loc->name
also. From this patch, we will generate loc->name from loc->path
Change-Id: I24a79554748139504ec09f77930f8208d3805977
BUG: 1236128
Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
Reviewed-on: http://review.gluster.org/11459
Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Joseph Fernandes
Diffstat (limited to 'xlators/features/changetimerecorder/src/ctr-helper.h')
-rw-r--r-- | xlators/features/changetimerecorder/src/ctr-helper.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/xlators/features/changetimerecorder/src/ctr-helper.h b/xlators/features/changetimerecorder/src/ctr-helper.h index 8fd16963a4e..0c4f3e2cd8c 100644 --- a/xlators/features/changetimerecorder/src/ctr-helper.h +++ b/xlators/features/changetimerecorder/src/ctr-helper.h @@ -180,12 +180,12 @@ do {\ } while (0) /*Clear and fill the ctr_link_context with values*/ -#define FILL_CTR_LINK_CX(ctr_link_cx, _pargfid, _basename, _basepath)\ +#define FILL_CTR_LINK_CX(ctr_link_cx, _pargfid, _basename, _basepath, label)\ do {\ - GF_ASSERT (ctr_link_cx);\ - GF_ASSERT (_pargfid);\ - GF_ASSERT (_basename);\ - GF_ASSERT (_basepath);\ + GF_VALIDATE_OR_GOTO ("ctr", ctr_link_cx, label);\ + GF_VALIDATE_OR_GOTO ("ctr", _pargfid, label);\ + GF_VALIDATE_OR_GOTO ("ctr", _basename, label);\ + GF_VALIDATE_OR_GOTO ("ctr", _basepath, label);\ memset (ctr_link_cx, 0, sizeof (*ctr_link_cx));\ ctr_link_cx->pargfid = &_pargfid;\ ctr_link_cx->basename = _basename;\ |