Hello community,

here is the log from the commit of package iotop for openSUSE:12.1:Update:Test 
checked in at 2011-12-05 15:35:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:12.1:Update:Test/iotop (Old)
 and      /work/SRC/openSUSE:12.1:Update:Test/.iotop.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "iotop", Maintainer is "[email protected]"

Changes:
--------
--- /work/SRC/openSUSE:12.1:Update:Test/iotop/iotop.changes     2011-12-05 
15:35:16.000000000 +0100
+++ /work/SRC/openSUSE:12.1:Update:Test/.iotop.new/iotop.changes        
2011-12-05 15:35:16.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Nov 29 03:28:47 UTC 2011 - [email protected]
+
+- Explain that iotop now requires root(bnc#732927).
+
+-------------------------------------------------------------------

New:
----
  iotop-root-permission.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ iotop.spec ++++++
--- /var/tmp/diff_new_pack.1IS4lb/_old  2011-12-05 15:35:17.000000000 +0100
+++ /var/tmp/diff_new_pack.1IS4lb/_new  2011-12-05 15:35:17.000000000 +0100
@@ -24,6 +24,7 @@
 Summary:        Top Like UI to Show Per-Process I/O Going on
 Source:         http://guichaz.free.fr/iotop/files/iotop-%{version}.tar.bz2
 Source1:        %{name}-rpmlintrc
+Patch0:         %{name}-root-permission.patch
 Url:            http://guichaz.free.fr/iotop/
 Group:          System/Monitoring
 License:        GPLv2
@@ -44,6 +45,7 @@
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %__python setup.py build

++++++ iotop-root-permission.patch ++++++
commit 635b5838e95ed85767434207e463173fd91b6040
Author: Guillaume Chazarain <[email protected]>
Date:   Sat Oct 15 18:39:32 2011 +0200

    Explain that iotop now requires root.
    https://lkml.org/lkml/2011/10/1/170
    
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=1a51410abe7d0ee4b1d112780f46df87d3621043

Index: iotop-0.4.3/iotop/ui.py
===================================================================
--- iotop-0.4.3.orig/iotop/ui.py
+++ iotop-0.4.3/iotop/ui.py
@@ -459,10 +459,19 @@ def run_iotop_window(win, options):
     ui.run()
 
 def run_iotop(options):
-    if options.batch:
-        return run_iotop_window(None, options)
-    else:
-        return curses.wrapper(run_iotop_window, options)
+    try:
+        if options.batch:
+            return run_iotop_window(None, options)
+        else:
+            return curses.wrapper(run_iotop_window, options)
+    except OSError, e:
+        if e.errno == errno.EPERM:
+            print >> sys.stderr, e
+            print >> sys.stderr, ('iotop requires root or the NET_ADMIN '
+                                  'capability.')
+            sys.exit(1)
+        else:
+            raise
 
 #
 # Profiling
-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to