parent
4cc952f0ca
commit
88a0b292d9
|
@ -9,9 +9,9 @@
|
|||
#error only libtransmission should #include this header.
|
||||
#endif
|
||||
|
||||
#include <cstdint> // uint64_t
|
||||
#include <cstdint>
|
||||
#include <optional>
|
||||
#include <utility> // std::pair
|
||||
#include <utility>
|
||||
|
||||
#include "transmission.h"
|
||||
|
||||
|
@ -48,11 +48,17 @@ private:
|
|||
|
||||
struct Val
|
||||
{
|
||||
Val& operator=(Val const&) = delete;
|
||||
Val& operator=(Val&&) = default;
|
||||
Val() = default;
|
||||
Val() noexcept = default;
|
||||
Val(Val const&) = delete;
|
||||
Val(Val&&) = default;
|
||||
Val& operator=(Val const&) = delete;
|
||||
Val(Val&& that) noexcept {
|
||||
*this = std::move(that);
|
||||
}
|
||||
Val& operator=(Val&& that) noexcept {
|
||||
std::swap(this->fd_, that.fd_);
|
||||
std::swap(this->writable_, that.writable_);
|
||||
return *this;
|
||||
}
|
||||
~Val();
|
||||
|
||||
tr_sys_file_t fd_ = TR_BAD_SYS_FILE;
|
||||
|
|
|
@ -49,6 +49,7 @@
|
|||
#include "torrent-metainfo.h"
|
||||
#include "torrent.h"
|
||||
#include "tr-assert.h"
|
||||
#include "tr-assert.h"
|
||||
#include "trevent.h" /* tr_runInEventThread() */
|
||||
#include "utils.h"
|
||||
#include "variant.h"
|
||||
|
@ -1771,7 +1772,7 @@ static void torrentCallScript(tr_torrent const* tor, char const* script)
|
|||
return;
|
||||
}
|
||||
|
||||
auto torrent_dir = std::string{ tor->currentDir() };
|
||||
auto torrent_dir = tr_pathbuf{ tor->currentDir() };
|
||||
tr_sys_path_native_separators(std::data(torrent_dir));
|
||||
|
||||
auto const cmd = std::array<char const*, 2>{ script, nullptr };
|
||||
|
|
Loading…
Reference in New Issue