merged stats fix from RC_0_16

This commit is contained in:
Arvid Norberg 2014-04-18 06:27:54 +00:00
parent 0b3df1c973
commit 15d4a0c55c
1 changed files with 4 additions and 6 deletions

View File

@ -216,12 +216,10 @@ namespace libtorrent
s->atime = file_time_to_posix(data.ftLastAccessTime);
s->mtime = file_time_to_posix(data.ftLastWriteTime);
s->mode = ((data.dwFileAttributes & FILE_ATTRIBUTE_NORMAL)
? file_status::regular_file : 0)
| ((data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
? file_status::directory : 0)
| ((data.dwFileAttributes & FILE_ATTRIBUTE_DEVICE)
? file_status::character_special : 0);
s->mode = (data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
? file_status::directory
: (data.dwFileAttributes & FILE_ATTRIBUTE_DEVICE)
? file_status::character_special : file_status::regular_file;
#else