diff options
author | Anuradha Talur <atalur@commvault.com> | 2018-11-29 12:54:21 -0800 |
---|---|---|
committer | Anuradha Talur <atalur@commvault.com> | 2019-04-10 10:50:31 -0700 |
commit | d82640511f51a79db6dabea8599c805028fefafb (patch) | |
tree | 75b45c9973c0d11d384577a1801c0835967b51a4 /xlators/features/cloudsync/src/cloudsync-common.c | |
parent | 734e6a7e389ea309d5528133ed5bd19064799f13 (diff) |
features/cloudsync : Added some new functions
This patch contains the following changes:
1) Store ID info will now be stored in the inode ctx
2) Added new readv type where read is made directly
from the remote store. This choice is made by
volume set operation.
3) cs_forget() was missing. Added it.
Change-Id: Ie3232b3d7ffb5313a03f011b0553b19793eedfa2
fixes: bz#1642168
Signed-off-by: Anuradha Talur <atalur@commvault.com>
Diffstat (limited to 'xlators/features/cloudsync/src/cloudsync-common.c')
-rw-r--r-- | xlators/features/cloudsync/src/cloudsync-common.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/xlators/features/cloudsync/src/cloudsync-common.c b/xlators/features/cloudsync/src/cloudsync-common.c index aee1f06a82a..445a31b90e7 100644 --- a/xlators/features/cloudsync/src/cloudsync-common.c +++ b/xlators/features/cloudsync/src/cloudsync-common.c @@ -11,6 +11,20 @@ #include "cloudsync-common.h" void +cs_xattrinfo_wipe(cs_local_t *local) +{ + if (local->xattrinfo.lxattr) { + if (local->xattrinfo.lxattr->file_path) + GF_FREE(local->xattrinfo.lxattr->file_path); + + if (local->xattrinfo.lxattr->volname) + GF_FREE(local->xattrinfo.lxattr->volname); + + GF_FREE(local->xattrinfo.lxattr); + } +} + +void cs_local_wipe(xlator_t *this, cs_local_t *local) { if (!local) @@ -40,5 +54,7 @@ cs_local_wipe(xlator_t *this, cs_local_t *local) if (local->remotepath) GF_FREE(local->remotepath); + cs_xattrinfo_wipe(local); + mem_put(local); } |