summaryrefslogtreecommitdiffstats
path: root/xlators/features/changetimerecorder/src
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/features/changetimerecorder/src')
-rw-r--r--xlators/features/changetimerecorder/src/changetimerecorder.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/xlators/features/changetimerecorder/src/changetimerecorder.c b/xlators/features/changetimerecorder/src/changetimerecorder.c
index 95ce08fea2b..b6ff18934fe 100644
--- a/xlators/features/changetimerecorder/src/changetimerecorder.c
+++ b/xlators/features/changetimerecorder/src/changetimerecorder.c
@@ -126,8 +126,9 @@ ctr_lookup_wind(call_frame_t *frame,
/* Copy hard link info*/
gf_uuid_copy (CTR_DB_REC(ctr_local).pargfid,
*((NEW_LINK_CX(ctr_inode_cx))->pargfid));
- strcpy (CTR_DB_REC(ctr_local).file_name,
- NEW_LINK_CX(ctr_inode_cx)->basename);
+ strncpy (CTR_DB_REC(ctr_local).file_name,
+ NEW_LINK_CX(ctr_inode_cx)->basename,
+ sizeof(CTR_DB_REC(ctr_local).file_name));
/* Since we are in lookup we can ignore errors while
* Inserting in the DB, because there may be many