diff options
Diffstat (limited to 'sysutils/gnome-system-monitor/files')
4 files changed, 62 insertions, 67 deletions
diff --git a/sysutils/gnome-system-monitor/files/patch-src::proctable.c b/sysutils/gnome-system-monitor/files/patch-src::proctable.c index 30ef6303d397..49a699641476 100644 --- a/sysutils/gnome-system-monitor/files/patch-src::proctable.c +++ b/sysutils/gnome-system-monitor/files/patch-src::proctable.c @@ -1,28 +1,7 @@ ---- src/proctable.c.orig Sun Nov 21 18:03:12 2004 -+++ src/proctable.c Mon Dec 6 22:10:55 2004 -@@ -535,6 +535,9 @@ - glibtop_get_proc_uid (&procuid, pid); - glibtop_get_proc_time (&proctime, pid); - newcputime = proctime.utime + proctime.stime; -+ if (proctime.frequency) { -+ newcputime /= (proctime.frequency/100); -+ } - model = gtk_tree_view_get_model (GTK_TREE_VIEW (procdata->tree)); +--- src/proctable.c.orig Tue Nov 30 01:28:31 2004 ++++ src/proctable.c Wed Dec 1 13:25:55 2004 +@@ -772,6 +772,12 @@ - wnck_pid_read_resource_usage (gdk_screen_get_display (gdk_screen_get_default ()), -@@ -645,6 +648,10 @@ - glibtop_get_proc_uid (&procuid, pid); - glibtop_get_proc_time (&proctime, pid); - newcputime = proctime.utime + proctime.stime; -+ if (proctime.frequency) { -+ newcputime /= (proctime.frequency/100); -+ } -+ - - wnck_pid_read_resource_usage (gdk_screen_get_display (gdk_screen_get_default ()), - pid, -@@ -745,6 +752,12 @@ - } +static int @@ -32,18 +11,15 @@ +} + static void - refresh_list (ProcData *data, const unsigned *pid_list, guint n) + refresh_list (ProcData *procdata, const unsigned *pid_list, const guint n) { -@@ -754,6 +767,8 @@ - GtkTreeModel *model = gtk_tree_view_get_model (GTK_TREE_VIEW (procdata->tree)); - guint i; +@@ -863,10 +869,15 @@ + + pid_list = glibtop_get_proclist (&proclist, which, arg); -+ qsort (pid_list, n, sizeof (*pid_list), pid_compare); ++ qsort(pid_list, proclist.number, sizeof (*pid_list), pid_compare); + - /* Add or update processes */ - for(i = 0; i < n; ++i) { - ProcInfo *info; -@@ -837,6 +852,9 @@ + /* FIXME: total cpu time elapsed should be calculated on an individual basis here ** should probably have a total_time_last gint in the ProcInfo structure */ glibtop_get_cpu (&cpu); total_time = cpu.total - total_time_last; diff --git a/sysutils/gnome-system-monitor/files/patch-src_interface.c b/sysutils/gnome-system-monitor/files/patch-src_interface.c new file mode 100644 index 000000000000..1b4276e7ee56 --- /dev/null +++ b/sysutils/gnome-system-monitor/files/patch-src_interface.c @@ -0,0 +1,21 @@ +--- src/interface.c.orig Wed Dec 1 13:23:26 2004 ++++ src/interface.c Wed Dec 1 13:24:00 2004 +@@ -529,12 +529,12 @@ + + model = gtk_tree_store_new (10, + GDK_TYPE_PIXBUF, +- G_TYPE_STRING, // device name +- G_TYPE_STRING, // directory +- G_TYPE_STRING, // type +- G_TYPE_STRING, // total +- G_TYPE_STRING, // free +- G_TYPE_STRING, // used ++ G_TYPE_STRING, /* device name */ ++ G_TYPE_STRING, /* directory */ ++ G_TYPE_STRING, /* type */ ++ G_TYPE_STRING, /* total */ ++ G_TYPE_STRING, /* free */ ++ G_TYPE_STRING, /* used */ + G_TYPE_FLOAT, + G_TYPE_FLOAT, + G_TYPE_FLOAT); diff --git a/sysutils/gnome-system-monitor/files/patch-src_openfiles.c b/sysutils/gnome-system-monitor/files/patch-src_openfiles.c new file mode 100644 index 000000000000..efdcef5f7882 --- /dev/null +++ b/sysutils/gnome-system-monitor/files/patch-src_openfiles.c @@ -0,0 +1,32 @@ +--- src/openfiles.c.orig Fri Jan 21 18:35:43 2005 ++++ src/openfiles.c Tue Jan 25 19:02:29 2005 +@@ -8,6 +8,7 @@ + #include <netdb.h> + #include <sys/types.h> + #include <sys/socket.h> ++#include <netinet/in.h> + #include <arpa/inet.h> + #include "procman.h" + #include "openfiles.h" +@@ -143,7 +144,7 @@ + const glibtop_open_files_entry *o2 = b; + + /* Falta manejar los diferentes tipos! */ +- return (o1->fd == o2->fd) && (o1->type == o1->type); // XXX! ++ return (o1->fd == o2->fd) && (o1->type == o1->type); /* XXX! */ + } + + +@@ -152,10 +153,10 @@ + { + ProcInfo *info; + GtkTreeModel *model; +- glibtop_open_files_entry *openfiles; +- glibtop_proc_open_files procmap; + GHashTable *new_maps; + gint i; ++ glibtop_open_files_entry *openfiles; ++ glibtop_proc_open_files procmap; + + info = g_object_get_data (G_OBJECT (tree), "selected_info"); + g_return_if_fail (info); diff --git a/sysutils/gnome-system-monitor/files/patch-src_util.c b/sysutils/gnome-system-monitor/files/patch-src_util.c deleted file mode 100644 index 288ccc26adc0..000000000000 --- a/sysutils/gnome-system-monitor/files/patch-src_util.c +++ /dev/null @@ -1,34 +0,0 @@ ---- src/util.c.orig Fri Dec 12 02:26:57 2003 -+++ src/util.c Fri Dec 12 02:35:38 2003 -@@ -16,6 +16,7 @@ - - #ifdef __FreeBSD__ - # include <errno.h> -+# include <termios.h> - # include <libutil.h> - #endif - -@@ -181,7 +182,11 @@ - * Make su think we're sending the password from a terminal: - */ - -+#ifndef __FreeBSD__ - if (((t_fd = OPEN_TTY()) < 0) || (grantpt(t_fd) < 0) || (unlockpt(t_fd) < 0)) { -+#else -+ if ((t_fd = OPEN_TTY()) < 0) { -+#endif - fprintf (stderr, "Unable to open a terminal\n"); - ABORT (root); - } -@@ -259,7 +264,11 @@ - } - } - -+#ifndef __FreeBSD__ - if(((pts = ptsname(t_fd)) == NULL) || ((t_fd = open(pts, O_RDWR | O_NOCTTY)) < 0)) { -+#else -+ if (((pts = ttyname(t_fd)) == NULL) || ((t_fd = open(pts, O_RDWR | O_NOCTTY)) < 0)) { -+#endif - perror ("Unable to open pseudo slave terminal"); - _exit (-1); - } |