fix deprecation warning

This commit is contained in:
Arvid Norberg 2013-10-07 07:45:36 +00:00
parent d45d193811
commit 2b7897700d
3 changed files with 7 additions and 1 deletions

View File

@ -347,6 +347,7 @@ namespace libtorrent
iterator end_deprecated() const { return m_files.end(); }
reverse_iterator rbegin_deprecated() const { return m_files.rbegin(); }
reverse_iterator rend_deprecated() const { return m_files.rend(); }
iterator file_at_offset_deprecated(size_type offset) const;
#endif // TORRENT_NO_DEPRECATE
// returns the number of files in the file_storage

View File

@ -484,7 +484,7 @@ namespace libtorrent
TORRENT_DEPRECATED_PREFIX
file_iterator file_at_offset(size_type offset) const TORRENT_DEPRECATED
{ return m_files.file_at_offset(offset); }
{ return m_files.file_at_offset_deprecated(offset); }
#endif // TORRENT_NO_DEPRECATE

View File

@ -229,6 +229,11 @@ namespace libtorrent
}
#ifndef TORRENT_NO_DEPRECATE
file_storage::iterator file_storage::file_at_offset_deprecated(size_type offset) const
{
return file_at_offset(offset);
}
file_storage::iterator file_storage::file_at_offset(size_type offset) const
{
// find the file iterator and file offset