exception: switch to public sdbus exception

SdBusError was intended to be a private error type inside sdbusplus.
Switch all catch locations to use the general sdbusplus::exception type.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: If9ecc60e370b7ab62e58dc1c3bfdd4051ee9c435
diff --git a/activation.cpp b/activation.cpp
index 8765181..0ab5eb5 100644
--- a/activation.cpp
+++ b/activation.cpp
@@ -27,7 +27,6 @@
 namespace softwareServer = sdbusplus::xyz::openbmc_project::Software::server;
 
 using namespace phosphor::logging;
-using sdbusplus::exception::SdBusError;
 using InternalFailure =
     sdbusplus::xyz::openbmc_project::Common::Error::InternalFailure;
 
@@ -48,7 +47,7 @@
     {
         this->bus.call_noreply(method);
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         if (e.name() != nullptr &&
             strcmp("org.freedesktop.systemd1.AlreadySubscribed", e.name()) == 0)
@@ -118,7 +117,7 @@
             return;
         }
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error in Get Delete Object",
                         entry("VERSIONPATH=%s", path.c_str()));
@@ -148,7 +147,7 @@
     {
         bus.call(method);
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         if (e.name() != nullptr && strcmp("System.Error.ELOOP", e.name()) == 0)
         {
@@ -193,7 +192,7 @@
                 return true;
             }
         }
-        catch (const SdBusError& e)
+        catch (const sdbusplus::exception::exception& e)
         {
             log<level::ERR>("Error in getting ApplyTime",
                             entry("ERROR=%s", e.what()));
@@ -221,7 +220,7 @@
     {
         auto reply = bus.call(method);
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ALERT>("Error in trying to reboot the Host. "
                           "The Host needs to be manually rebooted to complete "
@@ -287,7 +286,7 @@
         reply.read(fieldMode);
         return std::get<bool>(fieldMode);
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error in fieldModeEnabled getValue");
         elog<InternalFailure>();
diff --git a/functions.cpp b/functions.cpp
index 88c7841..0404d00 100644
--- a/functions.cpp
+++ b/functions.cpp
@@ -60,7 +60,7 @@
             return std::string{};
         }
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         return std::string{};
     }
@@ -84,7 +84,7 @@
         auto reply = bus.call(method);
         reply.read(objects);
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         return ManagedObjectType{};
     }
@@ -407,7 +407,7 @@
                       std::variant<PendingAttributesType>(pendingAttributes));
         bus.call(method);
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error setting the bios attribute",
                         entry("ERROR=%s", e.what()),
@@ -649,7 +649,7 @@
         auto reply = bus.call(getManagedObjects);
         reply.read(objects);
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         // Error querying the EntityManager interface. Return the match to have
         // the callback run if/when the interface appears in D-Bus.
diff --git a/item_updater.cpp b/item_updater.cpp
index d8cf45f..b57650a 100644
--- a/item_updater.cpp
+++ b/item_updater.cpp
@@ -233,7 +233,7 @@
             elog<InternalFailure>();
         }
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error in Mapper call");
         elog<InternalFailure>();
@@ -253,7 +253,7 @@
         auto strParam = std::get<std::string>(currentChassisState);
         return (strParam != CHASSIS_STATE_OFF);
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error in fetching current Chassis State",
                         entry("MAPPERRESPONSE=%s",
diff --git a/msl_verify.cpp b/msl_verify.cpp
index 36d4ffe..0efedf3 100644
--- a/msl_verify.cpp
+++ b/msl_verify.cpp
@@ -92,7 +92,7 @@
     {
         response.read(associations);
     }
-    catch (const sdbusplus::exception::SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Failed to read software associations",
                         entry("ERROR=%s", e.what()),
@@ -122,7 +122,7 @@
                 response.read(functionalVersion);
                 return std::get<std::string>(functionalVersion);
             }
-            catch (const sdbusplus::exception::SdBusError& e)
+            catch (const sdbusplus::exception::exception& e)
             {
                 log<level::ERR>(
                     "Failed to read version property",
diff --git a/static/item_updater_static.cpp b/static/item_updater_static.cpp
index 7695aa0..8eea808 100644
--- a/static/item_updater_static.cpp
+++ b/static/item_updater_static.cpp
@@ -20,7 +20,6 @@
 
 using namespace sdbusplus::xyz::openbmc_project::Common::Error;
 using namespace phosphor::logging;
-using sdbusplus::exception::SdBusError;
 
 // When you see server:: you know we're referencing our base class
 namespace server = sdbusplus::xyz::openbmc_project::Software::server;
diff --git a/utils.cpp b/utils.cpp
index 04b24bf..85c650e 100644
--- a/utils.cpp
+++ b/utils.cpp
@@ -38,7 +38,6 @@
 namespace utils
 {
 
-using sdbusplus::exception::SdBusError;
 using namespace phosphor::logging;
 
 constexpr auto HIOMAPD_PATH = "/xyz/openbmc_project/Hiomapd";
@@ -68,7 +67,7 @@
         }
         return mapperResponse[0].first;
     }
-    catch (const sdbusplus::exception::SdBusError& ex)
+    catch (const sdbusplus::exception::exception& ex)
     {
         log<level::ERR>("Mapper call failed", entry("METHOD=%d", "GetObject"),
                         entry("PATH=%s", path.c_str()),
@@ -87,7 +86,7 @@
     {
         bus.call_noreply(method);
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error in mboxd suspend call",
                         entry("ERROR=%s", e.what()));
@@ -106,7 +105,7 @@
     {
         bus.call_noreply(method);
     }
-    catch (const SdBusError& e)
+    catch (const sdbusplus::exception::exception& e)
     {
         log<level::ERR>("Error in mboxd suspend call",
                         entry("ERROR=%s", e.what()));