Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 696f267f authored by Mark Salyzyn's avatar Mark Salyzyn
Browse files

libsysutils: Get rid of warnings

- UNUSED argument warnings
- Remove LOG_NDEBUG define

Change-Id: I48b0942adfdb7a46a7693e580bc6ed5a685b0d5b
parent 0ea3624b
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -21,11 +21,14 @@

#include <sysutils/FrameworkCommand.h>

#define UNUSED __attribute__((unused))

FrameworkCommand::FrameworkCommand(const char *cmd) {
    mCommand = cmd;
}

int FrameworkCommand::runCommand(SocketClient *c, int argc, char **argv) {
int FrameworkCommand::runCommand(SocketClient *c UNUSED, int argc UNUSED,
                                 char **argv UNUSED) {
    SLOGW("Command %s has no run handler!", getCommand());
    errno = ENOSYS;
    return -1;
+3 −1
Original line number Diff line number Diff line
@@ -27,6 +27,8 @@

static const int CMD_BUF_SIZE = 1024;

#define UNUSED __attribute__((unused))

FrameworkListener::FrameworkListener(const char *socketName, bool withSeq) :
                            SocketListener(socketName, true, withSeq) {
    init(socketName, withSeq);
@@ -37,7 +39,7 @@ FrameworkListener::FrameworkListener(const char *socketName) :
    init(socketName, false);
}

void FrameworkListener::init(const char *socketName, bool withSeq) {
void FrameworkListener::init(const char *socketName UNUSED, bool withSeq) {
    mCommands = new FrameworkCommandCollection();
    errorRate = 0;
    mCommandCount = 0;
+0 −2
Original line number Diff line number Diff line
@@ -29,8 +29,6 @@
#include <sysutils/SocketListener.h>
#include <sysutils/SocketClient.h>

#define LOG_NDEBUG 0

SocketListener::SocketListener(const char *socketName, bool listen) {
    init(socketName, -1, listen, false);
}