Skip to content

Commit 1e6b33e

Browse files
author
Konstantin Osipov
committed
Fix compiler warnings in my_atomic.h
1 parent 813ad38 commit 1e6b33e

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

include/atomic/x86-gcc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@
8888
*/
8989
#define make_atomic_add_body64 \
9090
int64 tmp=*a; \
91-
while (!my_atomic_cas64(a, &tmp, tmp+v)); \
91+
while (!my_atomic_cas64(a, &tmp, tmp+v)) ; \
9292
v=tmp;
9393

9494
/*

include/my_atomic.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,13 +77,13 @@
7777
#ifndef make_atomic_add_body
7878
#define make_atomic_add_body(S) \
7979
int ## S tmp=*a; \
80-
while (!my_atomic_cas ## S(a, &tmp, tmp+v)); \
80+
while (!my_atomic_cas ## S(a, &tmp, tmp+v)) ; \
8181
v=tmp;
8282
#endif
8383
#ifndef make_atomic_fas_body
8484
#define make_atomic_fas_body(S) \
8585
int ## S tmp=*a; \
86-
while (!my_atomic_cas ## S(a, &tmp, v)); \
86+
while (!my_atomic_cas ## S(a, &tmp, v)) ; \
8787
v=tmp;
8888
#endif
8989
#ifndef make_atomic_load_body

0 commit comments

Comments
 (0)