diff options
author | monsta <[email protected]> | 2016-03-01 17:43:35 +0300 |
---|---|---|
committer | monsta <[email protected]> | 2016-03-01 17:43:35 +0300 |
commit | 93363c4e1081af38ade51eaf4739dc220414ac9e (patch) | |
tree | 35055a3762929d2450ca15f01e5a8181feebce1c /src | |
parent | 939d32b56e3bfaf51e604ecda4363223ea6a6753 (diff) | |
download | mate-system-monitor-93363c4e1081af38ade51eaf4739dc220414ac9e.tar.bz2 mate-system-monitor-93363c4e1081af38ade51eaf4739dc220414ac9e.tar.xz |
remove some dead code
Diffstat (limited to 'src')
-rw-r--r-- | src/util.h | 37 |
1 files changed, 0 insertions, 37 deletions
@@ -13,21 +13,6 @@ using std::string; -template<typename T> -inline int procman_cmp(T x, T y) -{ - if (x == y) - return 0; - - if (x < y) - return -1; - - return 1; -} - -#define PROCMAN_CMP(X, Y) procman_cmp((X), (Y)) -#define PROCMAN_RCMP(X, Y) procman_cmp((Y), (X)); - /* check if logind is running */ #define LOGIND_RUNNING() (access("/run/systemd/seats/", F_OK) >= 0) @@ -61,28 +46,6 @@ inline string make_string(char *c_str) } - - -template<typename Map> -class UnrefMapValues - : public std::unary_function<void, Map> -{ -public: - void operator()(const typename Map::value_type &it) const - { - if (it.second) - g_object_unref(it.second); - } -}; - - -template<typename Map> -inline void unref_map_values(Map &map) -{ - std::for_each(map.begin(), map.end(), UnrefMapValues<Map>()); -} - - namespace procman { gchar* format_duration_for_display(unsigned centiseconds); |