--- xsysinfo-1.7.orig/debian/README.source +++ xsysinfo-1.7/debian/README.source @@ -0,0 +1,4 @@ +This package uses dpatch to handle patches against upstream source code; you +can find additional information about dpatch at + + /usr/share/doc/dpatch/ --- xsysinfo-1.7.orig/debian/rules +++ xsysinfo-1.7/debian/rules @@ -0,0 +1,62 @@ +#!/usr/bin/make -f +# debian/rules for xsysinfo + +include /usr/share/dpatch/dpatch.make + +CDEBUGFLAGS = -Wall -g +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CDEBUGFLAGS += -O0 +else + CDEBUGFLAGS += -O2 +endif + +build: build-stamp +build-stamp: patch + dh_testdir + + xmkmf + $(MAKE) CDEBUGFLAGS="$(CDEBUGFLAGS)" xsysinfo + + touch build-stamp + +clean: unpatch + dh_testdir + dh_testroot + rm -f build-stamp + + [ ! -f Makefile ] || $(MAKE) distclean + + dh_clean + +install: build + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + + $(MAKE) DESTDIR=$(CURDIR)/debian/xsysinfo install + +# Build architecture-independent files here. +binary-indep: build install +# We have nothing to do by default. + +# Build architecture-dependent files here. +binary-arch: build install + dh_testdir + dh_testroot + dh_installchangelogs CHANGES + dh_installdocs README + dh_installmenu + dh_installman debian/xsysinfo.man + dh_link + dh_strip + dh_compress + dh_fixperms + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install --- xsysinfo-1.7.orig/debian/control +++ xsysinfo-1.7/debian/control @@ -0,0 +1,16 @@ +Source: xsysinfo +Section: utils +Priority: optional +Maintainer: tony mancill +Build-Depends: debhelper (>= 5), libxaw7-dev, xutils-dev, libsm-dev, libice-dev, dpatch +Standards-Version: 3.9.2 +Vcs-Git: git://git.debian.org/git/collab-maint/xsysinfo.git +Vcs-Browser: http://git.debian.org/?p=collab-maint/xsysinfo.git + +Package: xsysinfo +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: display some Linux kernel parameters in graphical form + This X client is like a mix of top, free and xload with the difference that + the values are shown in form of a horizontal bar. The displayed values are: + CPU load, CPU idle, memory and swap sizes. --- xsysinfo-1.7.orig/debian/copyright +++ xsysinfo-1.7/debian/copyright @@ -0,0 +1,54 @@ +This is the Debian GNU/Linux prepackaged version of xsysinfo. + +This package was put together by Michael Meskes , +from sources obtained from: +sunsite.unc.edu:/pub/Linux/system/status/xstatus/xsysinfo-1.6.tar.gz + +Version 1.7 is based on sources distributed with Mandrake Linux 10.2. + +It is was maintained, for some time, by Hugo Haas . +It is now maintained by Sandro Tosi + +Upstream Author: + + Gabor Herr + +Copyright: + + Copyright 1992, 1993 by Gabor Herr + Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts, + and the Massachusetts Institute of Technology, Cambridge, Massachusetts. + +License: + + Permission to use, copy, modify, distribute, and sell this software + and its documentation for any purpose is hereby granted without fee, + provided that the above copyright notice appear in all copies and + that both that copyright notice and this permission notice appear in + supporting documentation, and that may name is not used in + advertising or publicity pertaining to distribution of the software + without specific, written prior permission. I make no representations + about the suitability of this software for any purpose. It is + provided "as is" without express or implied warranty. + +On a Debian system the complete text of the BSD License can be found in +the file `/usr/share/common-licenses/BSD' + +Additional notes are: + + Permission to use, copy, modify, and distribute this software and its + documentation for any purpose and without fee is hereby granted, + provided that the above copyright notice appear in all copies and that + both that copyright notice and this permission notice appear in + supporting documentation, and that the names of Gabor Herr or Digital or MIT + not be + used in advertising or publicity pertaining to distribution of the + software without specific, written prior permission. + + GABOR HERR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING + ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL + GABOR HERR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR + ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, + ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS + SOFTWARE. --- xsysinfo-1.7.orig/debian/compat +++ xsysinfo-1.7/debian/compat @@ -0,0 +1 @@ +5 --- xsysinfo-1.7.orig/debian/changelog +++ xsysinfo-1.7/debian/changelog @@ -0,0 +1,302 @@ +xsysinfo (1.7-9) unstable; urgency=low + + * debian/control + - Remove Sandro Tosi from the Maintainer field (Close: #634227) + - Add Vcs-Git and Vcs-Browser fields + + -- tony mancill Thu, 21 Jul 2011 22:26:55 -0700 + +xsysinfo (1.7-8) unstable; urgency=low + + * debian/control + - updated my email address + - bump Standards-Version to 3.8.0 + + added debian/README.source + - added ${misc:Depends} to bin package depends + - uncapitalized short description + * debian/copyright + - updated my email address + + -- Sandro Tosi Fri, 06 Feb 2009 00:12:58 +0100 + +xsysinfo (1.7-7) unstable; urgency=low + + * debian/menu + - updated to new menu policy + * debian/control + - bump Standard-Version to 3.7.3 + * debian/xsysinfo.man + - moved here since currently at the same level of upstream code + * debian/patches/bts-341866_xsysinfo.man.dpatch + - removed and merged with debian/xsysinfo.man + * debian/rules + - added "xsysinfo" target to make in build target + - added doc installation filenames explicit parameter to dh_installdocs + - used $(MAKE) in build target to allow parallel compilation + - removed patch/unpatch target and added dpatch.make include + * debian/docs + - removed + * debian/patches/30_restore_pristine_code.dpatch + - added to remove direct upstream code changes + * debian/copyright + - clear separation of upstream author, copyright and license + - added local reference to BSD license + * debian/patches/40_bts-441378_fix_buffer_length.dpatch + - added to increase the buffer length, otherwise on amd64 system it + doesn't work (Closes: 441378) + * debian/patches/50_bts-442085_fix_cpu_bar.dpatch + - fix cpu bar under strange load; thanks to Stephan Seidl (Closes: 442085) + * debian/patches/10_bts-413807_fix_memleak.dpatch + - patch renamed to prepend ordering number + * debian/patches/20_bts-383368_fix_warning.dpatch + - patch renamed to prepend ordering number + + -- Sandro Tosi Mon, 21 Jan 2008 22:58:40 +0100 + +xsysinfo (1.7-6) unstable; urgency=low + + * fix memleak in getloadCB() (closes: #413807) + * added tony mancill to uploaders + + -- tony mancill Thu, 8 Mar 2007 09:59:28 -0800 + +xsysinfo (1.7-5) unstable; urgency=low + + * fix compile warnings (Closes: #383368) + * patches are now managed via dpatch + + -- Sandro Tosi Sat, 19 Aug 2006 01:01:36 +0200 + +xsysinfo (1.7-4) unstable; urgency=low + + * New maintainer. (Closes: #224842) + * debian/compat + - Bump to compatibility 5 + * debian/control + - Update Maintainer + - Bump to 3.7.2 version of debian policy + - set dependency against debhelper >= 5 + - add dependencies against libsm-dev, libice-dev + * debian/copyright + - Updated + - added licence for xsysinfo.man (GPL2, missing: thanks to James Westby + for notice it on #d-mentors@irc.d.o) + * debian/menu + - Just a little reformat + * XSysinfo.ad + - Corrected, reverting previous (now wrong) modification (as stated in + #341866) + * xsysinfo.man + - merged with a patch from BTS so this Closes: #341866 (the patch has been + saved in debian/patch/bts-341866_xsysinfo.man.patch) + * debian/rules + - add xsysinfo.man to dh_installman + + -- Sandro Tosi Sat, 29 Jul 2006 13:53:29 +0200 + +xsysinfo (1.7-3) unstable; urgency=low + + * QA upload + * Update for the Xorg 7.0 transition: update the menu file to look in + /usr/bin instead of /usr/X11R6/bin, and build-depend accordingly on + xutils-dev to ensure we're using a compatible imake. + * Drop unneeded build-dep on libxp-dev. + + -- Steve Langasek Fri, 21 Apr 2006 01:09:37 -0700 + +xsysinfo (1.7-2) unstable; urgency=low + + * QA upload + * Update build dependency on libxaw8-dev to libxaw7-dev to comply with XSF + plans + + -- David Nusinow Sun, 26 Mar 2006 21:20:03 -0500 + +xsysinfo (1.7-1) unstable; urgency=low + + * QA upload. + * Package is orphaned (see #224842); set maintainer to Debian QA Group. + * New upstream release. + * Remove object files from upstream tarball. Closes: #252172. + * Display swap on 2.6 kernels; thanks to Philip Martin for the patch. + Closes: #227187. + * Rename xsysinfo.1x to xsysinfo.man as this is what the Makefile expects. + * Switch to debhelper 4. + * Replace build dependencies on libxaw7-dev and xlibs-dev with libxaw8-dev + and libxp-dev (the latter only because of #324275). + * Add support for DEB_BUILD_OPTIONS=noopt and DEB_BUILD_OPTIONS=nostrip. + * debian/changelog: Remove obsolete Emacs local variables. + * debian/copyright: Remove outdated list of changes. + * debian/preinst: Remove potato compatibility code. + * Conforms to Standards version 3.6.2. + + -- Matej Vela Sun, 21 Aug 2005 14:58:15 +0200 + +xsysinfo (1.6-13) unstable; urgency=low + + * Using libxaw7 and libxaw7-dev (closes: #169988). + * Now compiles from source (closes: #164930). + + -- Hugo Haas Sun, 12 Jan 2003 12:30:27 -0500 + +xsysinfo (1.6-12.2) unstable; urgency=low + + * NMU; added a preinst script to delete + /usr/X11R6/lib/X11/app-defaults/Xsysinfo if it exists and is a symlink. + This is necessary because something made such a symlink in earlier + versions of this package, and it is no longer used. Really Closes: #86333 + + -- Joey Hess Sat, 24 Mar 2001 15:38:23 -0800 + +xsysinfo (1.6-12.1) unstable; urgency=low + + * NMU + * rebuilt against modern xlibs-dev to move app-defaults file + (Closes: #86333) + * rejiggered upstream app-defaults mono and color files to do things the + canonical way (no user-visible difference, aside from the renaming of + the XSysinfo-mono file to XSysinfo; now is the best time to do this + since they are becoming conffiles) + * lintian 1.20.9 clean + * debian/conffiles: add app-defaults file + * debian/control: + - added Build-Depends + - bumped Standards-Version to 3.5.2 + * debian/rules: + - remove call to dh_suidregister + + -- Branden Robinson Sat, 17 Mar 2001 22:19:41 -0500 + +xsysinfo (1.6-12) unstable; urgency=low + + * Changed priority to optional. + + -- Hugo Haas Wed, 21 Feb 2001 15:51:15 -0500 + +xsysinfo (1.6-11) unstable; urgency=low + + * app-defaults now go in /etc/X11/app-defaults/ (closes: #86333). + + -- Hugo Haas Mon, 19 Feb 2001 10:04:51 -0500 + +xsysinfo (1.6-10) unstable; urgency=low + + * Added a menu entry. + + -- Hugo Haas Tue, 5 Oct 1999 14:03:45 -0400 + +xsysinfo (1.6-9) unstable; urgency=low + + * Modified debian/rules so that it works with the new debhelper + (closes: #44597). + + -- Hugo Haas Wed, 8 Sep 1999 13:42:15 -0400 + +xsysinfo (1.6-8) unstable; urgency=low + + * Separate load meter for each processor in an SMP machine by + Philip Martin + * Moved the documentation tu /usr/share/doc. + + -- Hugo Haas Sat, 28 Aug 1999 15:32:12 -0400 + +xsysinfo (1.6-7) unstable; urgency=low + + * Added a man page for xsysinfo (closes:#35903). + + -- Hugo Haas Sat, 10 Jul 1999 17:54:45 -0400 + +xsysinfo (1.6-6) unstable; urgency=low + + * Removed the postinst script asking for color support (#37366). + + -- Hugo Haas Fri, 11 Jun 1999 15:16:38 -0400 + +xsysinfo (1.6-5) unstable; urgency=low + + * Applied patch by Ernst Kloppenburg : now + correctly indicates swap space used with a 2.2 kernel. + * This package has no upstream maintainer anymore (mail from Ronald Wahl + ). + + -- Hugo Haas Tue, 20 Apr 1999 17:24:09 +0100 + +xsysinfo (1.6-4) unstable; urgency=low + + * Defined the color setting as the default choice in the postinst script + (#36134). + + -- Hugo Haas Thu, 15 Apr 1999 20:59:14 +0200 + +xsysinfo (1.6-3) frozen unstable; urgency=low + + * Renamed CHANGES.gz into changelog.gz (lintian error) + + -- Hugo Haas Tue, 14 Apr 1998 15:53:22 +0100 + +xsysinfo (1.6-2) frozen unstable; urgency=low + + * Corrected a typo + * Changed resources (update interval in seconds, not in milli-seconds) + (fixes #20422) + + -- Hugo Haas Mon, 30 Mar 1998 22:21:32 +0100 + +xsysinfo (1.6-1) unstable; urgency=low + + * New maintainer + * New upstream release (#17977) + * Updated to standards 2.4.0.0 + * Used debhelper + + -- Hugo Haas Wed, 11 Mar 1998 20:10:21 +0000 + +xsysinfo (1.5-4) unstable; urgency=LOW + + * Fixed mixed libc6 dependencies. + + -- Syrus Nemat-Nasser Thu, 13 Nov 1997 21:53:01 +0100 + +xsysinfo (1.5-3) unstable; urgency=LOW + + * Created a postinst selection of app-defaults between color and mono. + + -- Syrus Nemat-Nasser Wed, 1 Oct 1997 21:19:14 +0000 + +xsysinfo (1.5-2) unstable; urgency=LOW + + * Fixed bugs #12652, #12904, and #13084 (obsolete dependency) + * First version compiled against libc6 + * Made the app-defaults to be conffiles + * Made the default app-default selection color instead of mono + + -- Syrus Nemat-Nasser Wed, 1 Oct 1997 21:19:14 +0000 + +xsysinfo (1.5-1) unstable; urgency=LOW + + * Upgraded to new upstream version + * Changed to new source packing scheme + * New maintainer + + -- Syrus Nemat-Nasser Thu, 24 Oct 1996 23:43:04 -0700 + + +Tue May 14 11:53:15 MET DST 1996 Michael Meskes + + xsysinfo (1.2-1): + + * Added Debian files + +Wed Jun 5 15:09:49 MET DST 1996 Michael Meskes + + xsysinfo (1.2-2): + + * Added /usr/doc/xsysinfo directory (Bug#3211) + +Sun Jun 30 16:27:17 MET DST 1996 Michael Meskes + + xsysinfo (1.2-3): + + * New naming scheme + + * Gzip manpage --- xsysinfo-1.7.orig/debian/menu +++ xsysinfo-1.7/debian/menu @@ -0,0 +1,4 @@ +?package(xsysinfo):needs="x11" \ + section="Applications/System/Monitoring" \ + title="XSysInfo" \ + command="/usr/bin/xsysinfo" --- xsysinfo-1.7.orig/debian/xsysinfo.man +++ xsysinfo-1.7/debian/xsysinfo.man @@ -0,0 +1,118 @@ +.\" Copyright (c) 1999-2005 Roland Rosenfeld +.\" +.\" This manual page is free software; you can redistribute it and/or modify +.\" it under the terms of the GNU General Public License as published by +.\" the Free Software Foundation; either version 2 of the License, or +.\" (at your option) any later version. +.\" +.\" This program is distributed in the hope that it will be useful, +.\" but WITHOUT ANY WARRANTY; without even the implied warranty of +.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.\" GNU General Public License for more details. +.\" +.\" You should have received a copy of the GNU General Public License +.\" along with this program; if not, write to the Free Software +.\" Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +.\" +.\" This manual page is written especially for Debian Linux. +.\" +.TH XSYSINFO 1x "December 2005" "Debian Project" "Debian GNU/Linux" +.SH NAME +xsysinfo \- Display Linux kernel parameters in graphical form +.SH SYNOPSIS +.B xsysinfo [-help] [-update +.IB n ] +.B [-[no]title] [-[no]labels] [-[no]loadavg] [-[no]load] [-[no]mem] +.B [-[no]swap] [-[no]smp] +.SH DESCRIPTION +.B Xsysinfo +is an X application to display some Linux kernel parameters in +graphical form. It is like a mix of top, free and xload with the +difference that the values are shown in form of a horizontal bar. The +displayed values are: CPU load average, CPU load, memory and swap +sizes (details see below). +.SH OPTIONS +.TP +.BI -update " n" +Set update rate to +.I n +milli-seconds +.TP +.B -title +Show title string +.TP +.B -notitle +Don't show title string +.TP +.B -labels +Show gauge labels +.TP +.B -nolabels +Don't show gauge labels +.TP +.B -loadavg +Show CPU load average value +.TP +.B -noloadavg +Don't show CPU load average value +.TP +.B -load +Show CPU load value +.TP +.B -noload +Don't show CPU load value +.TP +.B -smp +Show separate SMP loads +.TP +.B -nosmp +Don't show separate SMP loads. +.TP +.B -mem +Show memory info +.TP +.B -nomem +Don't show memory info +.TP +.B -swap +Show swap info +.TP +.B -noswap +Don't show swap info +.TP +.B -help +Display options +.SH DISPLAY +.B Xsysinfo +display the following values: +.TP +.B CPU load average +CPU load average between 0.000-8.000. The gauge's bar is subdivided +into segments, where one segment represents a load value of 1.0. The +bar's full length is automatically scaled, depending on the displayed +value. +.TP +.B CPU load +percentage CPU load time to CPU idle time subdivided in three +segments: user load, system load and nice load. On an SMP system the +-smp option replaces the single total load meter with a separate meter +for each processor. +.TP +.B Memory +The memory gauge's bar is subdivided into two segments with the amount +of physical memory, which is used by processes on the left and +physical memory used for the page and buffer cache on the right. The +length of the whole bar, which is the sum of these two values, shows +the amount of physical memory currently used by the system. +.TP +.B Swap +The percentage of swap space used by the system to total amount of +swap space. +.SH AUTHORS +.B Xsyinfo +is written by Gabor Herr and +currently maintained by Ronald Wahl +. +.PP +This manual page was created by Roland Rosenfeld +for the Debian GNU/Linux system (but may be used by others). --- xsysinfo-1.7.orig/debian/patches/10_bts-413807_fix_memleak.dpatch +++ xsysinfo-1.7/debian/patches/10_bts-413807_fix_memleak.dpatch @@ -0,0 +1,28 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## bts-413807_fix_memleak.dpatch by tony mancill +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: bts-413807_fix_memleak + +@DPATCH@ +diff -uarb xsysinfo~/xsysinfo.c xsysinfo/xsysinfo.c +--- xsysinfo~/xsysinfo.c 1999-05-04 22:58:03.000000000 -0700 ++++ xsysinfo/xsysinfo.c 2007-03-07 11:49:20.000000000 -0800 +@@ -116,11 +116,15 @@ + XtPointer client_data; + XtPointer call_data; + { ++ static char cpuLoadBuffer[7]; + struct load load; + XgBarGaugeValues *gauge = (XgBarGaugeValues *) call_data; + +- load.cpu = (char *)malloc(7*sizeof(char)); +- strcpy(load.cpu, (char *)client_data); ++ // 20070307 ++ // this char buffer is never freed ++ //load.cpu = (char *)malloc(7*sizeof(char)); ++ load.cpu = cpuLoadBuffer; ++ strncpy(load.cpu, (char *)client_data, 7); + get_load(&load); + + gauge->values[0] = norm(load.user, load.total); --- xsysinfo-1.7.orig/debian/patches/30_restore_pristine_code.dpatch +++ xsysinfo-1.7/debian/patches/30_restore_pristine_code.dpatch @@ -0,0 +1,59 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 30_restore_pristine_code.dpatch by Sandro Tosi +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: New patch generated from xsysinfo 1.7-7 diff.gz + +@DPATCH@ + +--- xsysinfo-1.7.orig/sysinfo.c ++++ xsysinfo-1.7/sysinfo.c +@@ -24,6 +24,7 @@ + + #include "sysinfo.h" + #include ++#include + #include + #include + #include +@@ -35,12 +36,22 @@ + + static char buffer[1024]; + ++/* reread rewritten by Ernst Kloppenburg */ ++/* Now works with Linux 2.2 */ ++ + static void reread( int fd, char *message ) + { +- if ( lseek( fd, 0L, 0 ) == 0 && +- read( fd, buffer, sizeof(buffer) - 1 ) > 0 ) +- return; +- ++ int i; ++ int bytesread; ++ ++ if ( lseek( fd, 0L, 0 ) == 0 ) { ++ bytesread = read( fd, buffer, sizeof(buffer) - 1 ); ++ if ( bytesread < (sizeof(buffer) - 1) ) { ++ buffer[bytesread] = 0x0; ++ return; ++ } ++ } ++ + perror(message); + exit(1); + } +@@ -75,9 +86,12 @@ + + /* Try new /proc/meminfo format first */ + *swapdevs = 1; ++ if ((result[0].shared = getentry("MemShared:", buffer)) < 0) { ++ /* Linux 2.4 has MemShared (but it's always zero?), 2.6 doesn't */ ++ result[0].shared = 0; ++ } + if ((result[0].total = getentry("MemTotal:", buffer)) < 0 || + (result[0].free = getentry("MemFree:", buffer)) < 0 || +- (result[0].shared = getentry("MemShared:", buffer)) < 0 || + (result[0].buffers = getentry("Buffers:", buffer)) < 0 || + (result[0].cache = getentry("Cached:", buffer)) < 0 || + (result[1].total = getentry("SwapTotal:", buffer)) < 0 || --- xsysinfo-1.7.orig/debian/patches/00list +++ xsysinfo-1.7/debian/patches/00list @@ -0,0 +1,5 @@ +10_bts-413807_fix_memleak +20_bts-383368_fix_warning +30_restore_pristine_code +40_bts-441378_fix_buffer_length +50_bts-442085_fix_cpu_bar --- xsysinfo-1.7.orig/debian/patches/20_bts-383368_fix_warning.dpatch +++ xsysinfo-1.7/debian/patches/20_bts-383368_fix_warning.dpatch @@ -0,0 +1,35 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## bts-383368_fix_warning.dpatch by Sandro Tosi +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: bts-383368_fix_warning + +@DPATCH@ +diff -urNad xsysinfo~/xsysinfo.c xsysinfo/xsysinfo.c +--- xsysinfo~/xsysinfo.c 2006-08-16 22:59:17.000000000 +0300 ++++ xsysinfo/xsysinfo.c 2006-08-16 22:58:52.000000000 +0300 +@@ -27,6 +27,7 @@ + #include + #include "BarGauge.h" + #include ++#include + #include "sysinfo.h" + + #define norm(x,max) ((max) == 0 ? 0 : (double)(x) / (max)) +@@ -325,9 +326,7 @@ + fprintf(stderr,"\nor one of the standard toolkit options.\n\n"); + } + +-main( argc, argv ) +- int argc; +-char **argv; ++int main( int argc, char **argv ) + { + Arg args[1]; + Widget toplevel; +@@ -358,4 +357,5 @@ + + XtRealizeWidget(toplevel); + XtAppMainLoop(context); ++ return 0; + } --- xsysinfo-1.7.orig/debian/patches/40_bts-441378_fix_buffer_length.dpatch +++ xsysinfo-1.7/debian/patches/40_bts-441378_fix_buffer_length.dpatch @@ -0,0 +1,21 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 40_bts-441378_fix_buffer_length.dpatch by Sandro Tosi +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: BTS 441378, increase the buffer length + +@DPATCH@ +diff -urNad xsysinfo~/sysinfo.c xsysinfo/sysinfo.c +--- xsysinfo~/sysinfo.c 2008-01-21 22:18:24.503408508 +0100 ++++ xsysinfo/sysinfo.c 2008-01-21 22:20:36.030903835 +0100 +@@ -34,7 +34,9 @@ + static int loadavg_fd; + static int swaps_fd; + +-static char buffer[1024]; ++// Sandro Tosi, 2008-01-21 ++// Size 16k, it must be bigger then any of /proc/{meminfo,loadavg,stat} ++static char buffer[16384]; + + /* reread rewritten by Ernst Kloppenburg */ + /* Now works with Linux 2.2 */ --- xsysinfo-1.7.orig/debian/patches/50_bts-442085_fix_cpu_bar.dpatch +++ xsysinfo-1.7/debian/patches/50_bts-442085_fix_cpu_bar.dpatch @@ -0,0 +1,41 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 50_bts-442085_fix_cpu_bar.dpatch by Stephan Seidl +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: BTS 442085: fix cpu bar under strange loads + +@DPATCH@ + +*** xsysinfo-1.7.orig-OLD/sysinfo.c Sat Aug 11 04:14:43 2007 +--- xsysinfo-1.7.orig/sysinfo.c Sun Aug 12 02:30:47 2007 +*************** +*** 185,192 **** +--- 185,212 ---- + loadptr = last_load + index; + + bufptr = strstr(bufptr, result->cpu); ++ #if (1) ++ { ++ /* from 2.6 .../Documentation/filesystems/proc.txt */ ++ unsigned long aux_us = 0, /* normal processes executing in user mode */ ++ aux_ni = 0, /* niced processes executing in user mode */ ++ aux_sy = 0, /* processes executing in kernel mode */ ++ aux_id = 0, /* twiddling thumbs */ ++ aux_wa = 0, /* waiting for I/O to complete */ ++ aux_hi = 0, /* servicing hardware interrupts */ ++ aux_si = 0; /* servicing softirqs */ ++ sscanf( bufptr, "%*s %lu %lu %lu %lu %lu %lu %lu\n", ++ &aux_us, &aux_ni, &aux_sy, &aux_id, ++ &aux_wa, &aux_hi, &aux_si ); ++ curr_load.user = aux_us; ++ curr_load.nice = aux_ni; ++ curr_load.system = aux_sy + aux_hi + aux_si; ++ curr_load.idle = aux_id + aux_wa; ++ } ++ #else + sscanf( bufptr, "%*s %lu %lu %lu %lu\n", &curr_load.user, + &curr_load.nice, &curr_load.system, &curr_load.idle ); ++ #endif + curr_load.total = curr_load.user + curr_load.nice + curr_load.system + + curr_load.idle; +