Skip to content

Commit

Permalink
Avoid std::move. Hopefully fixes kpu#91.
Browse files Browse the repository at this point in the history
  • Loading branch information
kpu committed Jun 15, 2017
1 parent 0d0bbb2 commit cdd7945
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion util/file_stream.hh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class FileStream : public FakeOStream<FileStream> {
fd_(out) {}

#if __cplusplus >= 201103L
FileStream(FileStream &&from) noexcept : buf_(std::move(from.buf_)), current_(from.current_), end_(from.end_), fd_(from.fd_) {
FileStream(FileStream &&from) noexcept : buf_(from.buf_.release()), current_(from.current_), end_(from.end_), fd_(from.fd_) {
from.end_ = reinterpret_cast<char*>(from.buf_.get());
from.current_ = from.end_;
}
Expand Down

0 comments on commit cdd7945

Please sign in to comment.