~ubuntu-branches/ubuntu/saucy/procps/saucy-proposed

« back to all changes in this revision

Viewing changes to debian/patches/top_irix.patch

  • Committer: Package Import Robot
  • Author(s): Oliver Grawert
  • Date: 2012-06-20 13:12:40 UTC
  • mfrom: (2.1.21 sid)
  • Revision ID: package-import@ubuntu.com-20120620131240-923p0d8q88bmk3ac
Tags: 1:3.3.3-2ubuntu1
* Merge from Debian unstable.  Remaining changes:
  - debian/sysctl.d (Ubuntu-specific):
    + 10-console-messages.conf: stop low-level kernel messages on console.
    + 10-kernel-hardening.conf: add the kptr_restrict setting
    + 10-keyboard.conf.powerpc: mouse button emulation on PowerPC.
    + 10-network-security.conf: enable rp_filter and SYN-flood protection.
    + 10-ptrace.conf: describe new PTRACE setting.
    + 10-zeropage.conf: safe mmap_min_addr value for graceful fall-back.
    + README: describe how this directory is supposed to work.
  - debian/upstart (Ubuntu-specific): upstart configuration to replace old
    style sysv init script

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
Description: Change formal of IRix mode when showing threads 
2
 
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
3
 
Bug-Debian: http://bugs.debian.org/459890
4
 
Reviewed-by: Craig Small <csmall@debian.org>
5
 
Index: b/top.c
6
 
===================================================================
7
 
--- a/top.c     2009-11-24 20:53:05.000000000 +1100
8
 
+++ b/top.c     2009-11-24 21:00:33.000000000 +1100
9
 
@@ -1783,7 +1783,8 @@
10
 
       confighlp(Winstk[i].rc.fieldscur);
11
 
    }
12
 
 
13
 
-   if(Rc.mode_irixps && smp_num_cpus>1){
14
 
+   if(Rc.mode_irixps && smp_num_cpus>1 &&
15
 
+      !(CHKw(Curwin, Show_THREADS))) {
16
 
       // good for 100 CPUs per process
17
 
       pcpu_max_value = 9999.0;
18
 
       Fieldstab[P_CPU].fmts = " %4.0f";
19
 
@@ -2570,6 +2571,15 @@
20
 
       case 'H':
21
 
          if (VIZCHKc) {
22
 
             TOGw(Curwin, Show_THREADS);
23
 
+            if(Rc.mode_irixps && smp_num_cpus>1 &&
24
 
+               !(CHKw(Curwin, Show_THREADS))){
25
 
+               // good for 100 CPUs per process
26
 
+               pcpu_max_value = 9999.0;
27
 
+               Fieldstab[P_CPU].fmts = " %4.0f";
28
 
+            } else {
29
 
+               pcpu_max_value = 99.9;
30
 
+               Fieldstab[P_CPU].fmts = " %#4.1f";
31
 
+            }
32
 
             show_msg(fmtmk("Show threads %s"
33
 
                , CHKw(Curwin, Show_THREADS) ? "On" : "Off"));
34
 
          }
35
 
@@ -2626,7 +2636,8 @@
36
 
          Rc.mode_irixps = !Rc.mode_irixps;
37
 
          show_msg(fmtmk("Irix mode %s", Rc.mode_irixps ? "On" : "Off"));
38
 
 #endif
39
 
-         if(Rc.mode_irixps && smp_num_cpus>1){
40
 
+         if(Rc.mode_irixps && smp_num_cpus>1 &&
41
 
+            !(CHKw(Curwin, Show_THREADS))){
42
 
             // good for 100 CPUs per process
43
 
             pcpu_max_value = 9999.0;
44
 
             Fieldstab[P_CPU].fmts = " %4.0f";