From 11f9f38d261f606fa3969b6d18b483c0bac7bce5 Mon Sep 17 00:00:00 2001 From: Ronan Abhamon Date: Mon, 2 Oct 2017 11:08:12 +0200 Subject: [PATCH] fix(Content): use move operator correctly --- src/content/content.cpp | 4 ++-- src/content/content.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/content/content.cpp b/src/content/content.cpp index 0557e3955..fb2b64113 100644 --- a/src/content/content.cpp +++ b/src/content/content.cpp @@ -107,9 +107,9 @@ void Content::setBody (const vector &body) { d->body = body; } -void Content::setBody (const std::vector &&body) { +void Content::setBody (std::vector &&body) { L_D(); - d->body = body; + d->body = move(body); } void Content::setBody (const string &body) { diff --git a/src/content/content.h b/src/content/content.h index b68e7a344..5c7b00c3a 100644 --- a/src/content/content.h +++ b/src/content/content.h @@ -50,7 +50,7 @@ public: std::string getBodyAsString () const; void setBody (const std::vector &body); - void setBody (const std::vector &&body); + void setBody (std::vector &&body); void setBody (const std::string &body); void setBody (const void *buffer, size_t size);