| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
Many thanks to @Explorer09 Kang-Che Sung (宋岡哲).
Also add a #error stanza to XUtils.h in case somebody forgets the beautiful mess GNU forces on us.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The standard isnan() function is defined to never throw FP exceptions
even when the argument is a "signaling" NaN. This makes isnan() more
expensive than (x != x) expression unless the compiler flag
'-fno-signaling-nans' is given.
Introduce functions isNaN(), isNonnegative(), isPositive(),
sumPositiveValues() and compareRealNumbers(), and replace isnan() in
htop's codebase with the new functions. These functions utilize
isgreater() and isgreaterequal() comparisons, which do not throw FP
exceptions on "quiet" NaNs, which htop uses extensively.
With isnan() removed, there is no need to suppress the warning
'-Wno-c11-extensions' in FreeBSD. Remove the code from 'configure.ac'.
Signed-off-by: Kang-Che Sung <explorer09@gmail.com>
|
| |
|
| |
|
|
|
|
|
| |
Now that the global format variable Process_pidFormat is gone, enable
the compiler warning -Wformat=2.
|
|
|
|
| |
Most of the time the parameter is passed to snprintf type functions
|
| |
|
|
|
|
|
| |
Small changes from review - keep headers sorted and keep local
variable declarations at the top of source files.
|
|
|
|
|
| |
Consistent with everything else involving platform-specific
calls from core htop code.
|
| |
|
|
|
|
| |
Information as seen by IWYU 0.12 + clang 9 on Linux
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reasoning:
- implementation was unsound -- broke down when I added a fairly
basic macro definition expanding to a struct initializer in a *.c
file.
- made it way too easy (e.g. via otherwise totally innocuous git
commands) to end up with timestamps such that it always ran
MakeHeader.py but never used its output, leading to overbuild noise
when running what should be a null 'make'.
- but mostly: it's just an awkward way of dealing with C code.
|
| |
|
|
|
|
|
| |
Calls marked with xSnprintf shouldn't fail.
Abort program cleanly if any of them does.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Rationale (copied from htop issue #471):
The function name "setValues" is misleading. For most OOP (object-
oriented programming) contexts, setXXX functions mean they will change
some member variables of an object into something specified in
function arguments. But in the *Meter_setValues() case, the new values
are not from the arguments, but from a hard-coded source. The caller
is not supposed to change the values[] to anything it likes, but
rather to "update" the values from the source. Hence, updateValues is
a better name for this family of functions.
|
|
|
|
|
|
|
|
|
| |
Two changes in this commit:
- All meters now explicitly specify "maxItems" property, even for just
1 item. (Exception is "container" CPU meter classes, which use
CUSTOM_METERMODE.)
- "maxItems" being 0 is now allowed. This will let bar meters and graph
meters render an empty meter.
|
|
|
|
|
|
|
|
|
| |
Fixes building on case-insensitive filesystems where String.h gets confused with <string.h>.
From d734dacea0a10d0465dad4e95b3421511e7da112 Mon Sep 17 00:00:00 2001
From: David Hunt <dhunt@iolanthe.attlocal.net>
Date: Sat, 11 Jul 2015 20:56:31 -0500
Subject: [PATCH 1/8] Rename String to StringUtils
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
Process.c
Process.h
linux/LinuxProcess.c
linux/LinuxProcess.h
linux/LinuxProcessList.c
unsupported/Platform.c
unsupported/Platform.h
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
Process.c
Process.h
ProcessList.c
ScreenManager.c
linux/LinuxProcessList.c
|
|/
|
|
|
| |
Kinda runs, but functionality from the original main loop
is still missing. Patience.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
See https://bugzilla.redhat.com/show_bug.cgi?id=987805 for details.
(thanks to Dawid Gajownik for the detailed analysis!)
|
|
|
|
| |
UTF-8 display of big numbers.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
contributed by Ian Hands
|