summaryrefslogtreecommitdiff
path: root/src/third_party/s2
diff options
context:
space:
mode:
authorTyler Brock <tyler.brock@gmail.com>2014-09-19 09:25:46 -0400
committerTyler Brock <tyler.brock@gmail.com>2014-09-19 09:34:32 -0400
commit1c7e562f611f92cc4b6aec07eed4aacbee070155 (patch)
treebe1b59dbb996095fc5d373262b3fadd6e03faf97 /src/third_party/s2
parentd0afb7a6c1fdfeefbed93bb3a5d3947fdb712ed4 (diff)
downloadmongo-1c7e562f611f92cc4b6aec07eed4aacbee070155.tar.gz
SERVER-15184 supress warning about memset overwriting vtable ptr
Diffstat (limited to 'src/third_party/s2')
-rw-r--r--src/third_party/s2/s2regioncoverer.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/third_party/s2/s2regioncoverer.cc b/src/third_party/s2/s2regioncoverer.cc
index fb1cb2a0715..fdf55b16e2f 100644
--- a/src/third_party/s2/s2regioncoverer.cc
+++ b/src/third_party/s2/s2regioncoverer.cc
@@ -113,7 +113,14 @@ S2RegionCoverer::Candidate* S2RegionCoverer::NewCandidate(S2Cell const& cell) {
size += sizeof(Candidate*) << max_children_shift();
}
Candidate* candidate = static_cast<Candidate*>(malloc(size));
+
+// Disable error on Clang 3.5
+// See SERVER-15184
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdynamic-class-memaccess"
memset(candidate, 0, size);
+#pragma clang diagnostic pop
+
candidate->cell = cell;
candidate->is_terminal = is_terminal;
++candidates_created_counter_;