From 4089001de1f22d6acd0b9f09996b71c716235551 Mon Sep 17 00:00:00 2001 From: Christophe Courtaut Date: Mon, 1 Jul 2013 14:57:17 +0200 Subject: [PATCH] rgw: Fix return value for swift user not found http://tracker.ceph.com/issues/1779 fixes #1779 Adjust the return value from rgw_get_user_info_by_swift call in RGW_SWIFT_Auth_Get::execute() to have the correct return code in response. --- src/rgw/rgw_swift_auth.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/rgw/rgw_swift_auth.cc b/src/rgw/rgw_swift_auth.cc index b0be5d459387..d0987e103335 100644 --- a/src/rgw/rgw_swift_auth.cc +++ b/src/rgw/rgw_swift_auth.cc @@ -181,7 +181,10 @@ void RGW_SWIFT_Auth_Get::execute() user_str = user; if ((ret = rgw_get_user_info_by_swift(store, user_str, info)) < 0) + { + ret = -EACCES; goto done; + } siter = info.swift_keys.find(user_str); if (siter == info.swift_keys.end()) { -- 2.47.3