aboutsummaryrefslogtreecommitdiff
path: root/paludis/repositories/e/metadata_xml.cc
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2013-05-16 20:03:48 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2013-05-22 23:19:18 +0100
commit78d9a9bf0758140e0e8c03c5e8d3288f74efbb51 (patch)
tree1c0b25ba6358e80d0fe535fb49e3cce8d243e6a3 /paludis/repositories/e/metadata_xml.cc
parent39834ca3b05fadb14f855a8ab6dcea98c35738a7 (diff)
downloadpaludis-78d9a9bf0758140e0e8c03c5e8d3288f74efbb51.tar.gz
paludis-78d9a9bf0758140e0e8c03c5e8d3288f74efbb51.tar.xz
Switch to std mutex and condition_variable
Diffstat (limited to 'paludis/repositories/e/metadata_xml.cc')
-rw-r--r--paludis/repositories/e/metadata_xml.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/paludis/repositories/e/metadata_xml.cc b/paludis/repositories/e/metadata_xml.cc
index 73d22ba63..216ab0a35 100644
--- a/paludis/repositories/e/metadata_xml.cc
+++ b/paludis/repositories/e/metadata_xml.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2010, 2011 Ciaran McCreesh
+ * Copyright (c) 2008, 2010, 2011, 2013 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -22,7 +22,6 @@
#include <paludis/util/pimp-impl.hh>
#include <paludis/util/singleton-impl.hh>
#include <paludis/util/map-impl.hh>
-#include <paludis/util/mutex.hh>
#include <paludis/util/hashes.hh>
#include <paludis/util/log.hh>
#include <paludis/util/fs_path.hh>
@@ -41,7 +40,7 @@ namespace paludis
template <>
struct Imp<MetadataXMLPool>
{
- mutable Mutex mutex;
+ mutable std::mutex mutex;
mutable Store store;
};
}
@@ -61,7 +60,7 @@ MetadataXMLPool::metadata_if_exists(const FSPath & f) const
Context context("When handling metadata.xml file '" + stringify(f) + "':");
FSPath f_real(f.realpath_if_exists());
- Lock lock(_imp->mutex);
+ std::unique_lock<std::mutex> lock(_imp->mutex);
Store::const_iterator i(_imp->store.find(f_real));
if (i != _imp->store.end())
return i->second;