diff --git a/include/mqttpublisherbase.h b/include/mqttpublisherbase.h new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/include/mqttpublisherbase.h diff --git a/include/mqttsubscriberbase.h b/include/mqttsubscriberbase.h new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/include/mqttsubscriberbase.h diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 543ce86..34432bc 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -31,9 +31,12 @@ include(compiler) include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/../logutils + ${CMAKE_CURRENT_SOURCE_DIR}/../include ) set(SRC_LIST + ${CMAKE_CURRENT_SOURCE_DIR}/mqttpublisherbase.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/mqttsubscriberbase.cpp ${CMAKE_CURRENT_SOURCE_DIR}/clientpaho.cpp ${CMAKE_CURRENT_SOURCE_DIR}/commondefs.cpp ${CMAKE_CURRENT_SOURCE_DIR}/connectionstatus.cpp diff --git a/src/compat-chrono.h b/src/compat-chrono.h index cec6df8..c383852 100644 --- a/src/compat-chrono.h +++ b/src/compat-chrono.h @@ -48,7 +48,11 @@ To ceil(const std::chrono::duration& d) { To t = std::chrono::duration_cast(d); if (t < d) + { return t + To{ 1 }; + } + + // or else... return t; } diff --git a/src/mqttpublisherbase.cpp b/src/mqttpublisherbase.cpp new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/src/mqttpublisherbase.cpp diff --git a/src/mqttsubscriberbase.cpp b/src/mqttsubscriberbase.cpp new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/src/mqttsubscriberbase.cpp