diff options
Diffstat (limited to 'xlators/lib/src/libxlator.c')
| -rw-r--r-- | xlators/lib/src/libxlator.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/xlators/lib/src/libxlator.c b/xlators/lib/src/libxlator.c index e8e22bb7830..8075fa0c29f 100644 --- a/xlators/lib/src/libxlator.c +++ b/xlators/lib/src/libxlator.c @@ -7,7 +7,7 @@ later), or the GNU General Public License, version 2 (GPLv2), in all cases as published by the Free Software Foundation. */ -#include "mem-types.h" + #include "libxlator.h" int marker_xtime_default_gauge[] = { @@ -198,10 +198,11 @@ cluster_markerxtime_cbk(call_frame_t *frame, void *cookie, xlator_t *this, } if (dict_get_ptr(dict, marker_xattr, (void **)&net_timebuf)) { + local->count[MCNT_NOTFOUND]++; + UNLOCK(&frame->lock); gf_log(this->name, GF_LOG_WARNING, "Unable to get <uuid>.xtime attr"); - local->count[MCNT_NOTFOUND]++; - goto unlock; + goto post_unlock; } if (local->count[MCNT_FOUND]) { @@ -221,7 +222,7 @@ cluster_markerxtime_cbk(call_frame_t *frame, void *cookie, xlator_t *this, } unlock: UNLOCK(&frame->lock); - +post_unlock: if (callcnt == 0) cluster_marker_unwind(frame, marker_xattr, local->net_timebuf, 8, dict); @@ -266,17 +267,17 @@ cluster_markeruuid_cbk(call_frame_t *frame, void *cookie, xlator_t *this, goto unlock; } else if (volmark->retval) { GF_FREE(local->volmark); - local->volmark = memdup(volmark, sizeof(*volmark)); + local->volmark = gf_memdup(volmark, sizeof(*volmark)); local->retval = volmark->retval; } else if ((volmark->sec > local->volmark->sec) || ((volmark->sec == local->volmark->sec) && (volmark->usec >= local->volmark->usec))) { GF_FREE(local->volmark); - local->volmark = memdup(volmark, sizeof(*volmark)); + local->volmark = gf_memdup(volmark, sizeof(*volmark)); } } else { - local->volmark = memdup(volmark, sizeof(*volmark)); + local->volmark = gf_memdup(volmark, sizeof(*volmark)); VALIDATE_OR_GOTO(local->volmark, unlock); gf_uuid_unparse(volmark->uuid, vol_uuid); if (volmark->retval) |
