We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e951fba commit 01b5177Copy full SHA for 01b5177
examples/mqtt/conn/conn.cpp
@@ -43,7 +43,9 @@ int main(int argc, char **argv)
43
mqtt::Client::Config conf;
44
conf.auto_reconnect_enable = true;
45
//conf.auto_reconnect_wait_sec = 5;
46
- conf.auto_reconnect_wait_sec_gen_func = [](int fail_count) { return 1 << fail_count; };
+ conf.auto_reconnect_wait_sec_gen_func = [](int fail_count) {
47
+ return 1 << std::min(fail_count, 4);
48
+ };
49
#if 0
50
conf.base.broker.domain = "cppmain.cpp";
51
conf.base.broker.port = 1883;
version.mk
@@ -21,4 +21,4 @@
21
# TBOX版本号
22
TBOX_VERSION_MAJOR := 1
23
TBOX_VERSION_MINOR := 12
24
-TBOX_VERSION_REVISION := 26
+TBOX_VERSION_REVISION := 27
0 commit comments