merge fixes from RC_1_0
This commit is contained in:
parent
bb48b6e83c
commit
c47699005f
|
@ -328,7 +328,10 @@ namespace libtorrent
|
||||||
|
|
||||||
// returns a peer_request representing the piece index, byte offset
|
// returns a peer_request representing the piece index, byte offset
|
||||||
// and size the specified file range overlaps. This is the inverse
|
// and size the specified file range overlaps. This is the inverse
|
||||||
// mapping ove map_block().
|
// mapping ove map_block(). Note that the ``peer_request`` return type
|
||||||
|
// is meant to hold bittorrent block requests, which may not be larger
|
||||||
|
// than 16 kiB. Mapping a range larger than that may return an overflown
|
||||||
|
// integer.
|
||||||
peer_request map_file(int file, boost::int64_t offset, int size) const;
|
peer_request map_file(int file, boost::int64_t offset, int size) const;
|
||||||
|
|
||||||
#ifndef TORRENT_NO_DEPRECATE
|
#ifndef TORRENT_NO_DEPRECATE
|
||||||
|
|
|
@ -349,7 +349,7 @@ namespace libtorrent
|
||||||
WIN32_FILE_ATTRIBUTE_DATA data;
|
WIN32_FILE_ATTRIBUTE_DATA data;
|
||||||
if (!GetFileAttributesEx(f.c_str(), GetFileExInfoStandard, &data))
|
if (!GetFileAttributesEx(f.c_str(), GetFileExInfoStandard, &data))
|
||||||
{
|
{
|
||||||
ec.assign(GetLastError(), boost::system::system_category());
|
ec.assign(GetLastError(), get_system_category());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -447,7 +447,7 @@ namespace libtorrent
|
||||||
|
|
||||||
if (CreateDirectory_(n.c_str(), 0) == 0
|
if (CreateDirectory_(n.c_str(), 0) == 0
|
||||||
&& GetLastError() != ERROR_ALREADY_EXISTS)
|
&& GetLastError() != ERROR_ALREADY_EXISTS)
|
||||||
ec.assign(GetLastError(), boost::system::system_category());
|
ec.assign(GetLastError(), get_system_category());
|
||||||
#else
|
#else
|
||||||
std::string n = convert_to_native(f);
|
std::string n = convert_to_native(f);
|
||||||
int ret = mkdir(n.c_str(), 0777);
|
int ret = mkdir(n.c_str(), 0777);
|
||||||
|
@ -562,7 +562,7 @@ namespace libtorrent
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (CopyFile_(f1.c_str(), f2.c_str(), false) == 0)
|
if (CopyFile_(f1.c_str(), f2.c_str(), false) == 0)
|
||||||
ec.assign(GetLastError(), boost::system::system_category());
|
ec.assign(GetLastError(), get_system_category());
|
||||||
#elif defined __APPLE__ && defined __MACH__ && MAC_OS_X_VERSION_MIN_REQUIRED >= 1050
|
#elif defined __APPLE__ && defined __MACH__ && MAC_OS_X_VERSION_MIN_REQUIRED >= 1050
|
||||||
std::string f1 = convert_to_native(inf);
|
std::string f1 = convert_to_native(inf);
|
||||||
std::string f2 = convert_to_native(newf);
|
std::string f2 = convert_to_native(newf);
|
||||||
|
@ -1011,7 +1011,7 @@ namespace libtorrent
|
||||||
if (RemoveDirectory_(f.c_str()) != 0)
|
if (RemoveDirectory_(f.c_str()) != 0)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
ec.assign(GetLastError(), boost::system::system_category());
|
ec.assign(GetLastError(), get_system_category());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
#else // TORRENT_WINDOWS
|
#else // TORRENT_WINDOWS
|
||||||
|
|
Loading…
Reference in New Issue