From: Yehuda Sadeh Date: Thu, 26 Jul 2018 00:49:43 +0000 (-0700) Subject: rgw: coroutine set_state() also sets retcode X-Git-Tag: v14.1.0~616^2~33 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=eac1dcf228e8dcb7d85d058932da026bc396a141;p=ceph.git rgw: coroutine set_state() also sets retcode Generally recode is needed for the caller, but current might need it too. Signed-off-by: Yehuda Sadeh --- diff --git a/src/rgw/rgw_coroutine.h b/src/rgw/rgw_coroutine.h index 6055eb3b70f9..e8173b3f0167 100644 --- a/src/rgw/rgw_coroutine.h +++ b/src/rgw/rgw_coroutine.h @@ -228,16 +228,15 @@ protected: stringstream error_stream; int set_state(int s, int ret = 0) { + retcode = ret; state = s; return ret; } int set_cr_error(int ret) { - state = RGWCoroutine_Error; - return ret; + return set_state(RGWCoroutine_Error, ret); } int set_cr_done() { - state = RGWCoroutine_Done; - return 0; + return set_state(RGWCoroutine_Done, 0); } void set_io_blocked(bool flag);