Author: zoltan
Date: 2005-03-30 08:25:09 -0500 (Wed, 30 Mar 2005)
New Revision: 42372

Modified:
   trunk/mono/mono/io-layer/ChangeLog
   trunk/mono/mono/io-layer/atomic.c
Log:
2005-03-30  Zoltan Varga  <[EMAIL PROTECTED]>

        * atomic.c (InterlockedIncrement): Fix fallback implementation of
        InterlockedIncrement and InterlockedDecrement. Fixes #74228.


Modified: trunk/mono/mono/io-layer/ChangeLog
===================================================================
--- trunk/mono/mono/io-layer/ChangeLog  2005-03-30 12:51:01 UTC (rev 42371)
+++ trunk/mono/mono/io-layer/ChangeLog  2005-03-30 13:25:09 UTC (rev 42372)
@@ -1,3 +1,8 @@
+2005-03-30  Zoltan Varga  <[EMAIL PROTECTED]>
+
+       * atomic.c (InterlockedIncrement): Fix fallback implementation of
+       InterlockedIncrement and InterlockedDecrement. Fixes #74228.
+
 2005-03-29  Sebastien Pouliot  <[EMAIL PROTECTED]>
 
        * io-layer.h: Add required header files for compiling with VS.NET.

Modified: trunk/mono/mono/io-layer/atomic.c
===================================================================
--- trunk/mono/mono/io-layer/atomic.c   2005-03-30 12:51:01 UTC (rev 42371)
+++ trunk/mono/mono/io-layer/atomic.c   2005-03-30 13:25:09 UTC (rev 42372)
@@ -91,8 +91,8 @@
                              (void *)&spin);
        thr_ret = pthread_mutex_lock(&spin);
        g_assert (thr_ret == 0);
-       
-       *dest++;
+
+       (*dest)++;
        ret= *dest;
        
        thr_ret = pthread_mutex_unlock(&spin);
@@ -115,7 +115,7 @@
        thr_ret = pthread_mutex_lock(&spin);
        g_assert (thr_ret == 0);
        
-       *dest--;
+       (*dest)--;
        ret= *dest;
        
        thr_ret = pthread_mutex_unlock(&spin);

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to