New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

misc: kill clang warnings #14549

Merged
merged 6 commits into from Apr 20, 2017

Conversation

Projects
None yet
3 participants
@tchaikov
Contributor

tchaikov commented Apr 14, 2017

No description provided.

tchaikov added some commits Apr 14, 2017

msg/async: only check errno if setsockopt() fails
Signed-off-by: Kefu Chai <kchai@redhat.com>
os/bluestore: asserts if fail to read "min_compat_ondisk_format"
Signed-off-by: Kefu Chai <kchai@redhat.com>

@tchaikov tchaikov requested review from yuyuyu101 and badone Apr 14, 2017

@@ -139,7 +139,8 @@ void NetHandler::set_priority(int sd, int prio, int domain)
}
} else if (domain == AF_INET6) {
r = ::setsockopt(sd, IPPROTO_IPV6, IPV6_TCLASS, &iptos, sizeof(iptos));
r = -errno;
if (r)
r = -errno;

This comment has been minimized.

@tchaikov

tchaikov Apr 14, 2017

Contributor

this is a bug fix.

@@ -3092,14 +3092,15 @@ TEST_P(StoreTest, LongnameSplitTest) {
t.create_collection(cid, 0);
cerr << "Creating collection " << cid << std::endl;
r = apply_transaction(store, &osr, std::move(t));
ASSERT_EQ(r, 0);
ASSERT_EQ(0, r);

This comment has been minimized.

@tchaikov

tchaikov Apr 14, 2017

Contributor

the first param is the expected value, and the second is the actual value. hence this change.

tchaikov added some commits Apr 14, 2017

os/filestore: avoid unnecessary temporary std::string
Signed-off-by: Kefu Chai <kchai@redhat.com>
msg/async/rdma: use type safe chunk_base
also silence the clang static analyzer warning of

Result of 'malloc' is converted to a pointer of type 'char', which is
incompatible with sizeof operand type 'class
Infiniband::MemoryManager::Chunk'

in Infiniband::MemoryManager::Cluster::fill()

Signed-off-by: Kefu Chai <kchai@redhat.com>
mon: do not assign ret code to 0 twice
silences warning of clang static ananlyzer:

Value stored to 't' is never read

Signed-off-by: Kefu Chai <kchai@redhat.com>

@liewegas liewegas merged commit d710e06 into ceph:master Apr 20, 2017

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details
default Build finished.
Details

@tchaikov tchaikov deleted the tchaikov:wip-kill-clang-warnings branch Apr 21, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment