diff options
author | Marcus Müller <marcus.mueller@ettus.com> | 2016-06-04 16:10:54 +0200 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2016-06-06 16:48:52 -0700 |
commit | 2004bbdb0298d7a2ce9aa274e4a9bbdd22792567 (patch) | |
tree | 8b74817563929ef90faa73a5c55e7eda45db6cea /host/CMakeLists.txt | |
parent | b2167e1ae42cb4afc1d474723028e50fa8aef48b (diff) | |
download | uhd-2004bbdb0298d7a2ce9aa274e4a9bbdd22792567.tar.gz uhd-2004bbdb0298d7a2ce9aa274e4a9bbdd22792567.tar.bz2 uhd-2004bbdb0298d7a2ce9aa274e4a9bbdd22792567.zip |
octoclock: Fix multi-line #define statements
Now, use `do{...} while(0)` to pack multiple statements
into a single one that isn't fragile.
Currently
```
if(state_just_right)
OCTOCLOCK_SEND_AND_RECV(all,the,options);
```
would introduce annoying bugs.
Generally, there's no good reason this is a `#define` rather than a
C/C++ function.
The `OCTOCLOCK_PACKET_MATCHES` should probably be a C function, too,
or simply an overloaded `==` operator on to `const octoclock_packet_t&`.
Diffstat (limited to 'host/CMakeLists.txt')
0 files changed, 0 insertions, 0 deletions