Skip to content

Commit

Permalink
remove unused functions and add helper to namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
AlwinEsch committed Sep 14, 2020
1 parent 3faf2bb commit 616cad4
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions src/sacd/sacd_core.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,11 @@

#include <memory>

std::string getFileExt(const std::string& s)
namespace
{

std::string getFileExt(const std::string& s)
{
size_t i = s.rfind('.', s.length());
if (i != std::string::npos)
{
Expand All @@ -29,17 +31,6 @@ std::string getFileExt(const std::string& s)
return ("");
}

void replaceExt(std::string& s, const std::string& newExt)
{

std::string::size_type i = s.rfind('.', s.length());

if (i != std::string::npos)
{
s.replace(i + 1, newExt.length(), newExt);
}
}

bool icasecmp(const std::string& l, const std::string& r)
{
return l.size() == r.size() && equal(l.cbegin(), l.cend(), r.cbegin(),
Expand All @@ -48,6 +39,7 @@ bool icasecmp(const std::string& l, const std::string& r)
});
}

} /* namespace */

bool sacd_core_t::g_is_our_content_type(const std::string& p_type)
{
Expand Down

0 comments on commit 616cad4

Please sign in to comment.