summaryrefslogtreecommitdiffstats
path: root/logd
diff options
context:
space:
mode:
authorAndreas Gampe <agampe@google.com>2015-07-27 11:04:37 -0700
committerSteve Kondik <steve@cyngn.com>2015-11-01 04:29:12 -0800
commit67c96c8d5a59e071983270ddd54bad8d0d744d95 (patch)
tree6af9886be60c8cd442cf30261766f78bf61be84a /logd
parent58be58ce08766780ea9941a46426942fd16cd0cf (diff)
downloadsystem_core-67c96c8d5a59e071983270ddd54bad8d0d744d95.zip
system_core-67c96c8d5a59e071983270ddd54bad8d0d744d95.tar.gz
system_core-67c96c8d5a59e071983270ddd54bad8d0d744d95.tar.bz2
Logd: Handle unused variable and fields
For build-system CFLAGS clean-up. Bug: 18632512 Change-Id: If81d6705b44e9a29f64c44c56ea633c031e831b7
Diffstat (limited to 'logd')
-rw-r--r--logd/CommandListener.cpp6
-rw-r--r--logd/CommandListener.h4
-rw-r--r--logd/LogKlog.cpp3
-rw-r--r--logd/LogKlog.h2
4 files changed, 3 insertions, 12 deletions
diff --git a/logd/CommandListener.cpp b/logd/CommandListener.cpp
index 5489cc9..489bea6 100644
--- a/logd/CommandListener.cpp
+++ b/logd/CommandListener.cpp
@@ -34,8 +34,7 @@
CommandListener::CommandListener(LogBuffer *buf, LogReader * /*reader*/,
LogListener * /*swl*/) :
- FrameworkListener(getLogSocket()),
- mBuf(*buf) {
+ FrameworkListener(getLogSocket()) {
// registerCmd(new ShutdownCmd(buf, writer, swl));
registerCmd(new ClearCmd(buf));
registerCmd(new GetBufSizeCmd(buf));
@@ -47,10 +46,9 @@ CommandListener::CommandListener(LogBuffer *buf, LogReader * /*reader*/,
registerCmd(new ReinitCmd());
}
-CommandListener::ShutdownCmd::ShutdownCmd(LogBuffer *buf, LogReader *reader,
+CommandListener::ShutdownCmd::ShutdownCmd(LogReader *reader,
LogListener *swl) :
LogCommand("shutdown"),
- mBuf(*buf),
mReader(*reader),
mSwl(*swl) {
}
diff --git a/logd/CommandListener.h b/logd/CommandListener.h
index 83e06b4..3877675 100644
--- a/logd/CommandListener.h
+++ b/logd/CommandListener.h
@@ -27,7 +27,6 @@
void reinit_signal_handler(int /*signal*/);
class CommandListener : public FrameworkListener {
- LogBuffer &mBuf;
public:
CommandListener(LogBuffer *buf, LogReader *reader, LogListener *swl);
@@ -37,12 +36,11 @@ private:
static int getLogSocket();
class ShutdownCmd : public LogCommand {
- LogBuffer &mBuf;
LogReader &mReader;
LogListener &mSwl;
public:
- ShutdownCmd(LogBuffer *buf, LogReader *reader, LogListener *swl);
+ ShutdownCmd(LogReader *reader, LogListener *swl);
virtual ~ShutdownCmd() {}
int runCommand(SocketClient *c, int argc, char ** argv);
};
diff --git a/logd/LogKlog.cpp b/logd/LogKlog.cpp
index d3a73a1..eff26f5 100644
--- a/logd/LogKlog.cpp
+++ b/logd/LogKlog.cpp
@@ -177,8 +177,6 @@ LogKlog::LogKlog(LogBuffer *buf, LogReader *reader, int fdWrite, int fdRead, boo
logbuf(buf),
reader(reader),
signature(CLOCK_MONOTONIC),
- fdWrite(fdWrite),
- fdRead(fdRead),
initialized(false),
enableLogging(true),
auditd(auditd) {
@@ -492,7 +490,6 @@ int LogKlog::log(const char *buf) {
}
}
} else if (isspace(cp[size])) {
- const char *b = cp;
cp += size;
while (isspace(*++cp));
// <PRI>[<TIME>] <tag> <tag> : message
diff --git a/logd/LogKlog.h b/logd/LogKlog.h
index a898c63..24b2685 100644
--- a/logd/LogKlog.h
+++ b/logd/LogKlog.h
@@ -27,8 +27,6 @@ class LogKlog : public SocketListener {
LogBuffer *logbuf;
LogReader *reader;
const log_time signature;
- const int fdWrite; // /dev/kmsg
- const int fdRead; // /proc/kmsg
// Set once thread is started, separates KLOG_ACTION_READ_ALL
// and KLOG_ACTION_READ phases.
bool initialized;