spek

Acoustic spectrum analyser
git clone http://git.hanabi.in/repos/spek.git
Log | Files | Refs | README

commit 3216b7e0865a496d240c92d17639ce652ce520f3
parent 39bd9e9d6cf650bb5bb15b554e3cd17bc9ee48e4
Author: Alexander Kojevnikov <alexander@kojevnikov.com>
Date:   Thu, 31 Mar 2011 08:30:37 +0800

Fix compile errors with valac >= 0.11.2

Diffstat:
Msrc/spek-pipeline.vala | 13+++++++++++++
Msrc/spek-window.vala | 4++++
2 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/src/spek-pipeline.vala b/src/spek-pipeline.vala @@ -45,8 +45,13 @@ namespace Spek { private float[] input; private float[] output; +#if VALA_0_12 + private unowned Thread<void*> reader_thread = null; + private unowned Thread<void*> worker_thread; +#else private unowned Thread reader_thread = null; private unowned Thread worker_thread; +#endif private Mutex reader_mutex; private Cond reader_cond; private Mutex worker_mutex; @@ -118,7 +123,11 @@ namespace Spek { worker_cond = new Cond (); try { +#if VALA_0_12 + reader_thread = Thread.create<void*> (reader_func, true); +#else reader_thread = Thread.create (reader_func, true); +#endif } catch (ThreadError e) { stop (); } @@ -144,7 +153,11 @@ namespace Spek { int size; try { +#if VALA_0_12 + worker_thread = Thread.create<void*> (worker_func, true); +#else worker_thread = Thread.create (worker_func, true); +#endif } catch (ThreadError e) { return null; } diff --git a/src/spek-window.vala b/src/spek-window.vala @@ -125,7 +125,11 @@ namespace Spek { } try { +#if VALA_0_12 + Thread.create<void*> (check_version, false); +#else Thread.create (check_version, false); +#endif } catch (ThreadError e) { } }