Skip to content

Commit daa2dec

Browse files
author
David Gräff
authored
Update hantekdsocontrol.cpp
Fixes #239
1 parent ea7b5cb commit daa2dec

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

openhantek/src/hantekdso/hantekdsocontrol.cpp

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1223,12 +1223,14 @@ void HantekDsoControl::run() {
12231223
// Start next capture if necessary by leaving out the break statement
12241224

12251225
if (!this->sampling) break;
1226-
#if __has_cpp_attribute(clang::fallthrough)
1227-
#define FALLTHROUGH [[clang::fallthrough]];
1228-
#elif __has_cpp_attribute(fallthrough)
1229-
#define FALLTHROUGH [[fallthrough]];
1230-
#else
1231-
#define FALLTHROUGH
1226+
#ifdef __has_cpp_attribute
1227+
#if __has_cpp_attribute(clang::fallthrough)
1228+
#define FALLTHROUGH [[clang::fallthrough]];
1229+
#elif __has_cpp_attribute(fallthrough)
1230+
#define FALLTHROUGH [[fallthrough]];
1231+
#else
1232+
#define FALLTHROUGH
1233+
#endif
12321234
#endif
12331235
else {
12341236
FALLTHROUGH

0 commit comments

Comments
 (0)