summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Jamroot.jam10
-rw-r--r--netfs/daemon/daemon.cpp4
-rw-r--r--netfs/fuse/netfs.cpp7
-rw-r--r--netfs/unittests/mockMount.cpp1
4 files changed, 17 insertions, 5 deletions
diff --git a/Jamroot.jam b/Jamroot.jam
index c13f68c..c49440c 100644
--- a/Jamroot.jam
+++ b/Jamroot.jam
@@ -17,10 +17,20 @@ project
<variant>release:<lto>on
<variant>debug:<warnings>extra
<variant>debug:<warnings-as-errors>on
+ <variant>debug:<cflags>-Wnon-virtual-dtor
<variant>debug:<cflags>-Wold-style-cast
<variant>debug:<cflags>-Wcast-align
+ <variant>debug:<cflags>-Wunused
+ <variant>debug:<cflags>-Woverloaded-virtual
+ <variant>debug:<cflags>-Wpedantic
<variant>debug:<cflags>-Wconversion
<variant>debug:<cflags>-Wsign-conversion
+ <variant>debug:<cflags>-Wnull-dereference
+ <variant>debug:<cflags>-Wdouble-promotion
+ <variant>debug:<cflags>-Wformat=2
+ <variant>debug:<cflags>-Wshadow
+ <toolset>gcc,<variant>debug:<cflags>-Wduplicated-cond
+ <toolset>gcc,<variant>debug:<cflags>-Wduplicated-branches
<toolset>gcc,<variant>debug:<cflags>-Wlogical-op
<toolset>gcc,<variant>debug:<cflags>-Wuseless-cast
<variant>coverage:<coverage>on
diff --git a/netfs/daemon/daemon.cpp b/netfs/daemon/daemon.cpp
index 4d245ac..831c409 100644
--- a/netfs/daemon/daemon.cpp
+++ b/netfs/daemon/daemon.cpp
@@ -32,9 +32,9 @@ NetFSDaemon::hostname()
// name = NetFSDaemonAdapter
void
-NetFSDaemon::start(const std::string & name, const Ice::CommunicatorPtr & ic, const Ice::StringSeq &)
+NetFSDaemon::start(const std::string & name, const Ice::CommunicatorPtr & c, const Ice::StringSeq &)
{
- this->ic = ic;
+ ic = c;
Ice::PropertiesPtr props = ic->getProperties();
LoadConfiguration(props->getProperty("NetFSD.ConfigPath"));
diff --git a/netfs/fuse/netfs.cpp b/netfs/fuse/netfs.cpp
index 77530ac..92242d4 100644
--- a/netfs/fuse/netfs.cpp
+++ b/netfs/fuse/netfs.cpp
@@ -6,11 +6,11 @@ class FuseImpl : public fuse_args, public NetFS::FuseApp {
public:
FuseImpl(int c, char ** v) :
fuse_args(FUSE_ARGS_INIT(c, v)), NetFS::FuseApp([this]() {
- Ice::StringSeq iceArgs;
- if (fuse_opt_parse(this, &iceArgs, nullptr, opt_parse) == -1) {
+ Ice::StringSeq rtn;
+ if (fuse_opt_parse(this, &rtn, nullptr, opt_parse) == -1) {
exit(-1);
}
- return iceArgs;
+ return rtn;
}())
{
openlog("netfs", LOG_CONS | LOG_PID | LOG_NDELAY, LOG_USER);
@@ -38,6 +38,7 @@ public:
void
vlogf(int priority, const char * fmt, va_list args) const noexcept override
{
+ // NOLINTNEXTLINE(clang-diagnostic-format-nonliteral)
vsyslog(priority, fmt, args);
}
};
diff --git a/netfs/unittests/mockMount.cpp b/netfs/unittests/mockMount.cpp
index 515d2cc..9195c1b 100644
--- a/netfs/unittests/mockMount.cpp
+++ b/netfs/unittests/mockMount.cpp
@@ -57,6 +57,7 @@ char *
FuseMountPoint::vstrdupf(const char * fmt, va_list args)
{
char * out {};
+ // NOLINTNEXTLINE(clang-diagnostic-format-nonliteral)
BOOST_REQUIRE_GE(vasprintf(&out, fmt, args), 0);
BOOST_REQUIRE(out);
return out;