Proper handling for unused parameters

Instead of ignoring the parameter warning via a compile flag we can
explicitly not give the parameter a valiable name. The compile will then
know that that the parameter is not expected to be used.

Signed-off-by: Zane Shelley <zshelle@us.ibm.com>
Change-Id: Idfc9c7b2ac9e2f6a3d220540a354b1b8e890bee8
diff --git a/attn/attn_handler.cpp b/attn/attn_handler.cpp
index 8a5042d..caf5265 100644
--- a/attn/attn_handler.cpp
+++ b/attn/attn_handler.cpp
@@ -363,14 +363,15 @@
  */
 bool activeAttn(uint32_t i_val, uint32_t i_mask, uint32_t i_attn)
 {
-    bool rc        = false; // assume attn masked and/or inactive
-    bool validAttn = true;  // known attention type
+    bool rc = false; // assume attn masked and/or inactive
 
     // if attention active
     if (0 != (i_val & i_attn))
     {
         std::stringstream ss;
 
+        bool validAttn = true; // known attention type
+
         switch (i_attn)
         {
             case SBE_ATTN:
diff --git a/attn/attn_logging.cpp b/attn/attn_logging.cpp
index a55ac55..48ee5be 100644
--- a/attn/attn_logging.cpp
+++ b/attn/attn_logging.cpp
@@ -476,16 +476,6 @@
     }
 }
 
-/** @brief Commit checkstop event to log */
-void eventCheckstop(std::map<std::string, std::string>& i_errors)
-{
-    // Additional data for log
-    std::map<std::string, std::string> additionalData;
-
-    // Create log event with additional data and FFDC data
-    event(EventType::Checkstop, additionalData, createFFDCFiles(nullptr, 0));
-}
-
 /**
  * Commit special attention TI event to log
  *
@@ -514,23 +504,6 @@
 }
 
 /**
- * Commit analyzer failure event to log
- *
- * Create an event log containing the specified error code.
- *
- * @param i_error - Error code
- */
-void eventHwDiagsFail(int i_error)
-{
-    // Additiona data for log
-    std::map<std::string, std::string> additionalData;
-    additionalData["ERROR_CODE"] = std::to_string(i_error);
-
-    // Create log event with additional data and FFDC data
-    event(EventType::HwDiagsFail, additionalData, createFFDCFiles(nullptr, 0));
-}
-
-/**
  * Commit attention handler failure event to log
  *
  * Create an event log containing the specified error code.
@@ -562,11 +535,12 @@
 {
     const char* data{nullptr};
     size_t length{0};
-    size_t prefix{0};
 
     // get field value
     if (0 == sd_journal_get_data(journal, field, (const void**)&data, &length))
     {
+        size_t prefix{0};
+
         // The data returned  by sd_journal_get_data will be prefixed with the
         // field name and "="
         const void* eq = memchr(data, '=', length);
diff --git a/attn/attn_logging.hpp b/attn/attn_logging.hpp
index 0103a52..edbc143 100644
--- a/attn/attn_logging.hpp
+++ b/attn/attn_logging.hpp
@@ -33,9 +33,6 @@
 template <level L>
 void trace(const char* i_message);
 
-/** @brief Commit checkstop event to log */
-void eventCheckstop(std::map<std::string, std::string>& i_errors);
-
 /** @brief Commit special attention TI event to log */
 void eventTerminate(std::map<std::string, std::string> i_additionalData,
                     char* i_tiInfoData);
@@ -43,9 +40,6 @@
 /** @brief Commit SBE vital event to log */
 void eventVital();
 
-/** @brief Commit analyzer failure event to log */
-void eventHwDiagsFail(int i_error);
-
 /** @brief Commit attention handler failure event to log */
 void eventAttentionFail(int i_error);