diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2019-02-13 12:47:23 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-02-13 12:47:23 -0500 |
| commit | cfef27e56ef3246a261ee0bf2810a46c08eebf8f (patch) | |
| tree | ac66ba3d1f7a037ad51f21bd54a236d5388f5916 /lib/stream.h | |
| parent | 01490ba25da576ec0a72c896559ebc6fa71484be (diff) | |
| parent | 8ed561e1f13d0afb019a7963238bdd43ad017bec (diff) | |
Merge pull request #3622 from mjstapp/fix_cpp_compile
libs, daemons: changes to permit c++ compilation
Diffstat (limited to 'lib/stream.h')
| -rw-r--r-- | lib/stream.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/stream.h b/lib/stream.h index 32b6fb5af1..5341bfa40b 100644 --- a/lib/stream.h +++ b/lib/stream.h @@ -28,6 +28,10 @@ #include "mpls.h" #include "prefix.h" +#ifdef __cplusplus +extern "C" { +#endif + /* * A stream is an arbitrary buffer, whose contents generally are assumed to * be in network order. @@ -115,9 +119,9 @@ struct stream_fifo { pthread_mutex_t mtx; /* number of streams in this fifo */ - _Atomic size_t count; + atomic_size_t count; #if defined DEV_BUILD - _Atomic size_t max_count; + atomic_size_t max_count; #endif struct stream *head; @@ -404,4 +408,8 @@ static inline uint8_t *ptr_get_be32(uint8_t *ptr, uint32_t *out) goto stream_failure; \ } while (0) +#ifdef __cplusplus +} +#endif + #endif /* _ZEBRA_STREAM_H */ |
