I found when a capture paramter in LAMDA operation is a reference type, an unexpected error happens.
So I've changed it to the parameter to be copied.
Change-Id: Id4b7ef68d85d0800df84331210c85fa035441229
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/5483
Reviewed-by: JungHo Kim <jhyo.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
auto requestKey = attributes.at(SCENE_KEY_LAST_SCENE).get<std::string>();
RCSRequest req(request.getResourceObject().lock(), request.getOCRequest());
-
+
ptr->execute(std::string(requestKey),
- [& req](int /*eCode*/)
+ [req](int /*eCode*/)
{
// TODO need to set error code.
// and need to set specific attr' but this attr not to be apply to RCSResourceObject.