]> granicus.if.org Git - libatomic_ops/commitdiff
Fix test_atomic_include for the case of missing CAS primitive
authorIvan Maidanski <ivmai@mail.ru>
Mon, 24 Oct 2011 11:45:10 +0000 (15:45 +0400)
committerIvan Maidanski <ivmai@mail.ru>
Mon, 24 Oct 2011 11:46:54 +0000 (15:46 +0400)
* tests/test_atomic_include.template (test_atomicXX): Add action for
the missing AO_compare_and_swap primitive.

tests/test_atomic.template

index f80eac83db65e756fc84820af13ff21f99da5872..d367d1adc8108ab49f1d123d3ac6d4f582de1383 100644 (file)
@@ -168,6 +168,7 @@ void test_atomicXX(void)
     TA_assert(x == 42);
 # else
     MISSING(AO_compare_and_swap);
+    if (x == 13) x = 42;
 # endif
 # if defined(AO_HAVE_orXX)
     AO_orXX(&x, 66);