[vlc-devel] commit: Fix flawed logic ( Rémi Denis-Courmont )
git version control
git at videolan.org
Tue Oct 28 18:29:59 CET 2008
vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Tue Oct 28 19:29:51 2008 +0200| [c26595a84486dc222c6a98699a3c3ec4e3eb093e] | committer: Rémi Denis-Courmont
Fix flawed logic
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c26595a84486dc222c6a98699a3c3ec4e3eb093e
---
src/libvlc.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/libvlc.c b/src/libvlc.c
index 2310996..dc757fc 100644
--- a/src/libvlc.c
+++ b/src/libvlc.c
@@ -151,10 +151,10 @@ void *vlc_hold (gc_object_t * p_gc)
#if defined (__GCC_HAVE_SYNC_COMPARE_AND_SWAP_4)
refs = __sync_add_and_fetch (&p_gc->refs, 1);
-#elif defined (WIN32) && defined (__GNUC__)
- refs = InterlockedIncrement (&p_gc->refs);
-#elif defined (WIN64) && defined (__GNUC__)
+#elif defined (WIN64)
refs = InterlockedIncrement64 (&p_gc->refs);
+#elif defined (WIN32)
+ refs = InterlockedIncrement (&p_gc->refs);
#elif defined(__APPLE__)
refs = OSAtomicIncrement32Barrier((int*)&p_gc->refs);
#else
@@ -178,10 +178,10 @@ void vlc_release (gc_object_t *p_gc)
#if defined (__GCC_HAVE_SYNC_COMPARE_AND_SWAP_4)
refs = __sync_sub_and_fetch (&p_gc->refs, 1);
-#elif defined (WIN32) && defined (__GNUC__)
- refs = InterlockedDecrement (&p_gc->refs);
-#elif defined (WIN64) && defined (__GNUC__)
+#elif defined (WIN64)
refs = InterlockedDecrement64 (&p_gc->refs);
+#elif defined (WIN32)
+ refs = InterlockedDecrement (&p_gc->refs);
#elif defined(__APPLE__)
refs = OSAtomicDecrement32Barrier((int*)&p_gc->refs);
#else
More information about the vlc-devel
mailing list