mirror of https://github.com/aristocratos/btop.git
Pass const string ref
This commit is contained in:
parent
6b1b9f8142
commit
4818441817
|
@ -27,7 +27,7 @@ using namespace Tools;
|
|||
|
||||
|
||||
namespace Proc {
|
||||
void proc_sorter(vector<proc_info>& proc_vec, string sorting, const bool reverse, const bool tree) {
|
||||
void proc_sorter(vector<proc_info>& proc_vec, const string& sorting, const bool reverse, const bool tree) {
|
||||
if (reverse) {
|
||||
switch (v_index(sort_vector, sorting)) {
|
||||
case 0: rng::stable_sort(proc_vec, rng::less{}, &proc_info::pid); break;
|
||||
|
|
|
@ -275,7 +275,7 @@ namespace Proc {
|
|||
};
|
||||
|
||||
//* Sort vector of proc_info's
|
||||
void proc_sorter(vector<proc_info>& proc_vec, string sorting, const bool reverse, const bool tree = false);
|
||||
void proc_sorter(vector<proc_info>& proc_vec, const string& sorting, const bool reverse, const bool tree = false);
|
||||
|
||||
//* Recursive sort of process tree
|
||||
void tree_sort(vector<tree_proc>& proc_vec, const string& sorting, const bool reverse, int& c_index, const int index_max, const bool collapsed = false);
|
||||
|
|
Loading…
Reference in New Issue