[Xfce4-commits] [apps/xfce4-taskmanager] 02/02: Sort the task list by pid, as we're going to use bsearch() (bug 14403)
noreply at xfce.org
noreply at xfce.org
Sat May 26 23:53:10 CEST 2018
This is an automated email from the git hooks/post-receive script.
l a n d r y p u s h e d a c o m m i t t o b r a n c h m a s t e r
in repository apps/xfce4-taskmanager.
commit 159c3c1d0ca1b7397453a08fc46469931af1bb7e
Author: Landry Breuil <landry at xfce.org>
Date: Sat May 26 23:52:46 2018 +0200
Sort the task list by pid, as we're going to use bsearch() (bug 14403)
---
src/task-manager-bsd.c | 2 ++
src/task-manager-freebsd.c | 2 ++
src/task-manager-linux.c | 2 ++
src/task-manager-skel.c | 2 ++
src/task-manager-solaris.c | 2 ++
5 files changed, 10 insertions(+)
diff --git a/src/task-manager-bsd.c b/src/task-manager-bsd.c
index 48b9e88..3fc3691 100644
--- a/src/task-manager-bsd.c
+++ b/src/task-manager-bsd.c
@@ -151,6 +151,8 @@ gboolean get_task_list (GArray *task_list)
}
free(kp);
+ g_array_sort (task_list, task_pid_compare_fn);
+
return TRUE;
}
diff --git a/src/task-manager-freebsd.c b/src/task-manager-freebsd.c
index f3f642d..cf48745 100644
--- a/src/task-manager-freebsd.c
+++ b/src/task-manager-freebsd.c
@@ -234,6 +234,8 @@ get_task_list (GArray *task_list)
kvm_close (kd);
+ g_array_sort (task_list, task_pid_compare_fn);
+
return TRUE;
}
diff --git a/src/task-manager-linux.c b/src/task-manager-linux.c
index 0ae3b0b..108453d 100644
--- a/src/task-manager-linux.c
+++ b/src/task-manager-linux.c
@@ -333,6 +333,8 @@ get_task_list (GArray *task_list)
g_dir_close (dir);
+ g_array_sort (task_list, task_pid_compare_fn);
+
return TRUE;
}
diff --git a/src/task-manager-skel.c b/src/task-manager-skel.c
index 8ca6d7e..76d6487 100644
--- a/src/task-manager-skel.c
+++ b/src/task-manager-skel.c
@@ -75,6 +75,8 @@ get_task_list (GArray *task_list)
}
}
+ g_array_sort (task_list, task_pid_compare_fn);
+
return TRUE;
}
diff --git a/src/task-manager-solaris.c b/src/task-manager-solaris.c
index 1f1b106..9b733ac 100644
--- a/src/task-manager-solaris.c
+++ b/src/task-manager-solaris.c
@@ -227,6 +227,8 @@ get_task_list (GArray *task_list)
g_dir_close (dir);
+ g_array_sort (task_list, task_pid_compare_fn);
+
return FALSE;
}
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list