summaryrefslogtreecommitdiffstats
path: root/sesman/chansrv
diff options
context:
space:
mode:
authorLaxmikant Rashinkar <LK.Rashinkar@gmail.com>2014-07-27 12:42:12 -0700
committerLaxmikant Rashinkar <LK.Rashinkar@gmail.com>2014-07-27 12:42:12 -0700
commit0311a82c0ab70e29c0a2a96424ca785d9fb2848f (patch)
tree0adae192e9a5a978c40306180029ce0fa76d51ac /sesman/chansrv
parent1c423dadf4c4ac1251faa015f14e3fcf55127879 (diff)
downloadxrdp-proprietary-0311a82c0ab70e29c0a2a96424ca785d9fb2848f.tar.gz
xrdp-proprietary-0311a82c0ab70e29c0a2a96424ca785d9fb2848f.zip
coverity: copy into fixed sized buffer
Diffstat (limited to 'sesman/chansrv')
-rw-r--r--sesman/chansrv/chansrv_fuse.c3
-rw-r--r--sesman/chansrv/chansrv_fuse.h2
2 files changed, 3 insertions, 2 deletions
diff --git a/sesman/chansrv/chansrv_fuse.c b/sesman/chansrv/chansrv_fuse.c
index 993b6594..1d78bbfb 100644
--- a/sesman/chansrv/chansrv_fuse.c
+++ b/sesman/chansrv/chansrv_fuse.c
@@ -1801,7 +1801,8 @@ void xfuse_devredir_cb_rename_file(void *vp, tui32 IoStatus)
}
old_xinode->parent_inode = fip->new_inode;
- strcpy(old_xinode->name, fip->new_name);
+ strncpy(old_xinode->name, fip->new_name, 1023);
+ old_xinode->name[1023] = 0;
if (fip->inode != fip->new_inode)
{
diff --git a/sesman/chansrv/chansrv_fuse.h b/sesman/chansrv/chansrv_fuse.h
index 41a73062..4638add5 100644
--- a/sesman/chansrv/chansrv_fuse.h
+++ b/sesman/chansrv/chansrv_fuse.h
@@ -34,7 +34,7 @@ struct xrdp_inode
time_t atime; /* Time of last access. */
time_t mtime; /* Time of last modification. */
time_t ctime; /* Time of last status change. */
- char name[256]; /* Dir or filename */
+ char name[1024]; /* Dir or filename */
tui32 device_id; /* for file system redirection */
char is_synced; /* dir struct has been read from */
/* remote device, done just once */