Mercurial > mxe-octave
comparison src/cairo-2-static-init.patch @ 2613:d6edff1d892a
update package cairo
author | Hans Petter Jansson <hpj@cl.no> |
---|---|
date | Mon, 04 Jun 2012 17:56:56 +0200 |
parents | |
children | 6aaa1723e277 |
comparison
equal
deleted
inserted
replaced
2612:ebe07cff1576 | 2613:d6edff1d892a |
---|---|
1 This file is part of MXE. | |
2 See index.html for further information. | |
3 | |
4 When DllMain is not being run, we need to initialize the font face mutex before using it. | |
5 | |
6 diff --git a/src/win32/cairo-win32-font.c b/src/win32/cairo-win32-font.c | |
7 index a65d81b..31d854d 100644 | |
8 --- a/src/win32/cairo-win32-font.c | |
9 +++ b/src/win32/cairo-win32-font.c | |
10 @@ -1912,6 +1912,8 @@ _cairo_win32_font_face_hash_table_destroy (void) | |
11 { | |
12 cairo_hash_table_t *hash_table; | |
13 | |
14 + CAIRO_MUTEX_INITIALIZE (); | |
15 + | |
16 /* We manually acquire the lock rather than calling | |
17 * _cairo_win32_font_face_hash_table_lock simply to avoid creating | |
18 * the table only to destroy it again. */ | |
19 @@ -1927,6 +1929,8 @@ _cairo_win32_font_face_hash_table_destroy (void) | |
20 static cairo_hash_table_t * | |
21 _cairo_win32_font_face_hash_table_lock (void) | |
22 { | |
23 + CAIRO_MUTEX_INITIALIZE (); | |
24 + | |
25 CAIRO_MUTEX_LOCK (_cairo_win32_font_face_mutex); | |
26 | |
27 if (unlikely (cairo_win32_font_face_hash_table == NULL)) |