diff options
Diffstat (limited to 'src/lib/base')
-rw-r--r-- | src/lib/base/scan_name.cpp | 16 | ||||
-rw-r--r-- | src/lib/base/scan_name.h | 18 |
2 files changed, 17 insertions, 17 deletions
diff --git a/src/lib/base/scan_name.cpp b/src/lib/base/scan_name.cpp index 2b32dc7d3..4688d0871 100644 --- a/src/lib/base/scan_name.cpp +++ b/src/lib/base/scan_name.cpp @@ -63,7 +63,7 @@ deref_aliases(const std::pair<size_t, std::string>& in) SCAN_Name::SCAN_Name(std::string algo_spec, const std::string& extra) : SCAN_Name(algo_spec) { - alg_name += extra; + m_alg_name += extra; } SCAN_Name::SCAN_Name(const char* algo_spec) : SCAN_Name(std::string(algo_spec)) @@ -72,7 +72,7 @@ SCAN_Name::SCAN_Name(const char* algo_spec) : SCAN_Name(std::string(algo_spec)) SCAN_Name::SCAN_Name(std::string algo_spec) { - orig_algo_spec = algo_spec; + m_orig_algo_spec = algo_spec; std::vector<std::pair<size_t, std::string> > name; size_t level = 0; @@ -119,7 +119,7 @@ SCAN_Name::SCAN_Name(std::string algo_spec) if(name.size() == 0) throw Decoding_Error(decoding_error + "Empty name"); - alg_name = name[0].second; + m_alg_name = name[0].second; bool in_modes = false; @@ -127,11 +127,11 @@ SCAN_Name::SCAN_Name(std::string algo_spec) { if(name[i].first == 0) { - mode_info.push_back(make_arg(name, i)); + m_mode_info.push_back(make_arg(name, i)); in_modes = true; } else if(name[i].first == 1 && !in_modes) - args.push_back(make_arg(name, i)); + m_args.push_back(make_arg(name, i)); } } @@ -157,21 +157,21 @@ std::string SCAN_Name::arg(size_t i) const if(i >= arg_count()) throw Invalid_Argument("SCAN_Name::arg " + std::to_string(i) + " out of range for '" + as_string() + "'"); - return args[i]; + return m_args[i]; } std::string SCAN_Name::arg(size_t i, const std::string& def_value) const { if(i >= arg_count()) return def_value; - return args[i]; + return m_args[i]; } size_t SCAN_Name::arg_as_integer(size_t i, size_t def_value) const { if(i >= arg_count()) return def_value; - return to_u32bit(args[i]); + return to_u32bit(m_args[i]); } std::mutex SCAN_Name::g_alias_map_mutex; diff --git a/src/lib/base/scan_name.h b/src/lib/base/scan_name.h index cc89bf998..43441e19c 100644 --- a/src/lib/base/scan_name.h +++ b/src/lib/base/scan_name.h @@ -41,12 +41,12 @@ class BOTAN_DLL SCAN_Name /** * @return original input string */ - const std::string& as_string() const { return orig_algo_spec; } + const std::string& as_string() const { return m_orig_algo_spec; } /** * @return algorithm name */ - const std::string& algo_name() const { return alg_name; } + const std::string& algo_name() const { return m_alg_name; } /** * @return algorithm name plus any arguments @@ -61,7 +61,7 @@ class BOTAN_DLL SCAN_Name /** * @return number of arguments */ - size_t arg_count() const { return args.size(); } + size_t arg_count() const { return m_args.size(); } /** * @param lower is the lower bound @@ -95,13 +95,13 @@ class BOTAN_DLL SCAN_Name * @return cipher mode (if any) */ std::string cipher_mode() const - { return (mode_info.size() >= 1) ? mode_info[0] : ""; } + { return (m_mode_info.size() >= 1) ? m_mode_info[0] : ""; } /** * @return cipher mode padding (if any) */ std::string cipher_mode_pad() const - { return (mode_info.size() >= 2) ? mode_info[1] : ""; } + { return (m_mode_info.size() >= 2) ? m_mode_info[1] : ""; } static void add_alias(const std::string& alias, const std::string& basename); @@ -110,10 +110,10 @@ class BOTAN_DLL SCAN_Name static std::mutex g_alias_map_mutex; static std::map<std::string, std::string> g_alias_map; - std::string orig_algo_spec; - std::string alg_name; - std::vector<std::string> args; - std::vector<std::string> mode_info; + std::string m_orig_algo_spec; + std::string m_alg_name; + std::vector<std::string> m_args; + std::vector<std::string> m_mode_info; }; } |