From 520203da69da7b6638cba569ca1975a7dd036b5e Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Fri, 26 Oct 2012 16:41:06 +0100 Subject: Fix up another deadlock. Tidy tests slightly. --- src/lib/film.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/lib/film.cc b/src/lib/film.cc index 81de2b518..9c351a64d 100644 --- a/src/lib/film.cc +++ b/src/lib/film.cc @@ -607,6 +607,7 @@ Film::thumb_file_for_frame (int n) const return thumb_base_for_frame(n) + ".png"; } +/** Must not be called with the _state_mutex locked */ string Film::thumb_base (int n) const { @@ -616,8 +617,6 @@ Film::thumb_base (int n) const string Film::thumb_base_for_frame (int n) const { - boost::mutex::scoped_lock lm (_state_mutex); - stringstream s; s.width (8); s << setfill('0') << n; @@ -631,6 +630,8 @@ Film::thumb_base_for_frame (int n) const /** @param n A thumb index. * @return The frame within the Film that it is for. + * + * Must not be called with the _state_mutex locked. */ int Film::thumb_frame (int n) const -- cgit v1.2.3