From 3c45393b2d1955cf172c95306a0ff79e1e0e925d Mon Sep 17 00:00:00 2001 From: Erik Ã…ldstedt Sund Date: Mon, 23 Oct 2017 23:23:10 +0200 Subject: Don't call copy_l before all other members are set This lead to undefined behaviour during copy. --- include/crow/json.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/crow/json.h b/include/crow/json.h index d8dbace..7cec94f 100644 --- a/include/crow/json.h +++ b/include/crow/json.h @@ -238,9 +238,9 @@ namespace crow start_ = r.start_; end_ = r.end_; key_ = r.key_; - copy_l(r); t_ = r.t_; option_ = r.option_; + copy_l(r); return *this; } rvalue& operator = (rvalue&& r) noexcept -- cgit v1.2.3-54-g00ecf