diff options
Diffstat (limited to 'source/Target/SectionLoadList.cpp')
-rw-r--r-- | source/Target/SectionLoadList.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/source/Target/SectionLoadList.cpp b/source/Target/SectionLoadList.cpp index ea9f7ea9911ca..598f49ca13de0 100644 --- a/source/Target/SectionLoadList.cpp +++ b/source/Target/SectionLoadList.cpp @@ -1,9 +1,8 @@ //===-- SectionLoadList.cpp -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// @@ -28,8 +27,9 @@ SectionLoadList::SectionLoadList(const SectionLoadList &rhs) } void SectionLoadList::operator=(const SectionLoadList &rhs) { - std::lock_guard<std::recursive_mutex> lhs_guard(m_mutex); - std::lock_guard<std::recursive_mutex> rhs_guard(rhs.m_mutex); + std::lock(m_mutex, rhs.m_mutex); + std::lock_guard<std::recursive_mutex> lhs_guard(m_mutex, std::adopt_lock); + std::lock_guard<std::recursive_mutex> rhs_guard(rhs.m_mutex, std::adopt_lock); m_addr_to_sect = rhs.m_addr_to_sect; m_sect_to_addr = rhs.m_sect_to_addr; } |