Each platform defines its own long opt macro, prefer printf

Follow up on the two items of feedback from cgzones review,
and resolve a build failure picked up by CI on Mac OS X.

Related to https://github.com/htop-dev/htop/pull/564
This commit is contained in:
Nathan Scott
2021-03-18 08:23:07 +11:00
parent 0ada9f325f
commit d56d23d91a
7 changed files with 26 additions and 16 deletions

View File

@ -22,6 +22,9 @@ in the source distribution for its full text.
#include "generic/uname.h"
#define PLATFORM_LONG_OPTIONS
#define PLATFORM_LONG_OPTIONS_USAGE
extern const ProcessField Platform_defaultFields[];
extern const SignalItem Platform_signals[];
@ -72,7 +75,7 @@ static inline void Platform_getRelease(char** string) {
*string = Generic_uname();
}
static bool Platform_getLongOption(ATTR_UNUSED int opt, ATTR_UNUSED int argc, ATTR_UNUSED char** argv) {
static inline bool Platform_getLongOption(ATTR_UNUSED int opt, ATTR_UNUSED int argc, ATTR_UNUSED char** argv) {
return false;
}