From 8ba9dc1b96d3bba164697fec7932f8f70baadb1b Mon Sep 17 00:00:00 2001 From: Christopher McArthur Date: Wed, 20 May 2020 21:13:16 -0400 Subject: [PATCH] correcting sstream reset --- include/jwt-cpp/jwt.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/jwt-cpp/jwt.h b/include/jwt-cpp/jwt.h index 60f9f3c..ef810ec 100644 --- a/include/jwt-cpp/jwt.h +++ b/include/jwt-cpp/jwt.h @@ -1420,6 +1420,7 @@ namespace jwt { std::ostringstream iss; iss << value_type(obj_header); std::string header = encode(iss.str()); + iss.str(std::string()); iss.clear(); iss << value_type(obj_payload); std::string payload = encode(iss.str());