diff options
Diffstat (limited to 'procps')
| -rw-r--r-- | procps/top.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/procps/top.c b/procps/top.c index e3f91c8f9..206f9e8be 100644 --- a/procps/top.c +++ b/procps/top.c | |||
| @@ -861,17 +861,22 @@ int top_main(int argc ATTRIBUTE_UNUSED, char **argv) | |||
| 861 | #else | 861 | #else |
| 862 | qsort(top, ntop, sizeof(top_status_t), (void*)(sort_function[0])); | 862 | qsort(top, ntop, sizeof(top_status_t), (void*)(sort_function[0])); |
| 863 | #endif /* FEATURE_TOP_CPU_USAGE_PERCENTAGE */ | 863 | #endif /* FEATURE_TOP_CPU_USAGE_PERCENTAGE */ |
| 864 | } else { /* TOPMEM */ | 864 | } |
| 865 | #if ENABLE_FEATURE_TOPMEM | ||
| 866 | else { /* TOPMEM */ | ||
| 865 | qsort(topmem, ntop, sizeof(topmem_status_t), (void*)topmem_sort); | 867 | qsort(topmem, ntop, sizeof(topmem_status_t), (void*)topmem_sort); |
| 866 | } | 868 | } |
| 869 | #endif | ||
| 867 | count = lines; | 870 | count = lines; |
| 868 | if (OPT_BATCH_MODE || count > ntop) { | 871 | if (OPT_BATCH_MODE || count > ntop) { |
| 869 | count = ntop; | 872 | count = ntop; |
| 870 | } | 873 | } |
| 871 | if (scan_mask == TOP_MASK) | 874 | if (scan_mask == TOP_MASK) |
| 872 | display_process_list(count, col); | 875 | display_process_list(count, col); |
| 876 | #if ENABLE_FEATURE_TOPMEM | ||
| 873 | else | 877 | else |
| 874 | display_topmem_process_list(count, col); | 878 | display_topmem_process_list(count, col); |
| 879 | #endif | ||
| 875 | clearmems(); | 880 | clearmems(); |
| 876 | if (iterations >= 0 && !--iterations) | 881 | if (iterations >= 0 && !--iterations) |
| 877 | break; | 882 | break; |
