To significantly simplify handling of resume data, the previous way of handling it is deprecated.
resume data is no longer passed in as a flat buffer in the add_torrent_params.
The add_torrent_params structure itself *is* the resume data now.
In order to parse the bencoded fast resume file (which is still the same format, and backwards compatible) use the read_resume_data() function.
Similarly, when saving resume data, the save_resume_data_alert now has a ``params`` field of type add_torrent_params which contains the resume data.
This object can be serialized into the bencoded form using write_resume_data().
This give the client full control over which properties should be loaded from the resume data and which should be controlled by the client directly.
The flags ``flag_override_resume_data``, ``flag_merge_resume_trackers``, ``flag_use_resume_save_path`` and ``flag_merge_resume_http_seeds`` have all been deprecated, since they are no longer needed.
The old API is still supported as long as libtorrent is built with deprecated functions enabled (which is the default).
It will be performing slightly better without deprecated functions present.
When building without deprecated features (``deprecated-functions=off``) the default behavior also changed to have rate limits apply to utp sockets too.
In order to be more consistent between the two build configurations, the default value has changed to true.
The new mechanism provided to apply special rate limiting rules is *peer classes*.
In order to implement the old behavior of not rate limiting uTP peers, one cans set up a peer class for all uTP peers, to make the normal peer classes not apply to them (which is where the rate limits are set).
Enum flags have been replaced by strongly typed flags.
This means their implicit conversion to and from ``int`` is deprecated.
For example, the following expressions are deprecated::
if ((atp.flags & add_torrent_params::flag_paused) == 0)
atp.flags = 0;
Insted say::
if (!(atp.flags & torrent_flags::paused))
atp.flags = {};
(Also note that in this specific example, the flags moved out of the ``add_torrent_params`` structure, but this is unrelated to them also having stronger types).