[Frugalware-git] fwsetup-ng: rename size conversion functions to something more aesthetic

James Buren ryuo at frugalware.org
Tue Aug 28 07:28:52 CEST 2012


Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=fwsetup-ng.git;a=commitdiff;h=adf129210c0a0a9550139b598f24e71632d68dcf

commit adf129210c0a0a9550139b598f24e71632d68dcf
Author: James Buren <ryuo at frugalware.org>
Date:   Mon Aug 27 22:15:48 2012 -0500

rename size conversion functions to something more aesthetic

diff --git a/Utility.cc b/Utility.cc
index 6a8ea60..62cd55a 100644
--- a/Utility.cc
+++ b/Utility.cc
@@ -69,7 +69,7 @@ bool zapLabel(const string &path)
return true;
}

-unsigned long long string_to_size(const string &text)
+unsigned long long stringToSize(const string &text)
{
unsigned long long n = 0;
char *p = 0;
@@ -109,7 +109,7 @@ unsigned long long string_to_size(const string &text)
return n;
}

-string size_to_string(unsigned long long n)
+string sizeToString(unsigned long long n)
{
unsigned long long divisor = 0;
const char *suffix = 0;
diff --git a/Utility.hh b/Utility.hh
index 23ec076..4988f2b 100644
--- a/Utility.hh
+++ b/Utility.hh
@@ -16,5 +16,5 @@ extern ofstream logfile;

pid_t execute(const string &cmd);
bool zapLabel(const string &path);
-unsigned long long string_to_size(const string &text);
-string size_to_string(unsigned long long n);
+unsigned long long stringToSize(const string &text);
+string sizeToString(unsigned long long n);


More information about the Frugalware-git mailing list