made trunk build on windows (mapped storage doesn't work right yet though)

This commit is contained in:
Arvid Norberg 2008-01-11 06:35:34 +00:00
parent 616a48b591
commit b5dedccb70
2 changed files with 6 additions and 1 deletions

View File

@ -210,7 +210,12 @@ namespace libtorrent
{
if (is_directory(st)) return file_view();
size_type s = fs::file_size(p);
#ifdef WIN32
// TODO: SetFileSize()
if (s < file_size) {}
#else
if (s < file_size) truncate(p.string().c_str(), file_size);
#endif
ret = m_files.back().open(p, mode, start, view_size, key);
}

View File

@ -1116,7 +1116,7 @@ namespace detail
#ifndef NDEBUG
std::string err = exc.what();
#endif
}
};
/*
namespace