Fix from Paul Whitaker: It is not safe to assume that free space

available at the top of the tree is indicative of free space anywhere in
the tree, because you may wish to redirect a mount point hierarchy.


git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/trunk/rdesktop@1434 423420c4-83ab-492f-b58f-81f9feb106b5
This commit is contained in:
Matt Chapman 2008-02-16 00:15:43 +00:00
parent 33669ac780
commit 3808350adb

2
disk.c
View File

@ -853,7 +853,7 @@ disk_set_information(RD_NTHANDLE handle, uint32 info_class, STREAM in, STREAM ou
in_uint32_le(in, length); /* file size */
/* prevents start of writing if not enough space left on device */
if (STATFS_FN(g_rdpdr_device[pfinfo->device_id].local_path, &stat_fs) == 0)
if (STATFS_FN(pfinfo->path, &stat_fs) == 0)
if (stat_fs.f_bfree * stat_fs.f_bsize < length)
return RD_STATUS_DISK_FULL;