fbshipit-source-id: 5d9ecf33fca19e4a6b8c979b879ec9dd82af1ef9

This commit is contained in:
Daniel Buchele
2018-06-25 04:33:04 -07:00
parent ec0b3829e2
commit 6fda334a00
70 changed files with 896 additions and 1464 deletions

View File

@@ -26,7 +26,7 @@
#define SONAR_LOG(message) \
__android_log_print(ANDROID_LOG_INFO, "sonar", "sonar: %s", message)
#else
#define SONAR_LOG(message) printf("sonar: %s", message)
#define SONAR_LOG(message) printf("sonar: %s\n", message)
#endif
#define CSR_FILE_NAME "app.csr"
@@ -99,7 +99,7 @@ SonarWebSocketImpl::~SonarWebSocketImpl() {
void SonarWebSocketImpl::start() {
folly::makeFuture()
.via(worker_->getEventBase())
.delayed(std::chrono::milliseconds(0))
.delayedUnsafe(std::chrono::milliseconds(0))
.then([this]() { startSync(); });
}
@@ -185,7 +185,7 @@ void SonarWebSocketImpl::connectSecurely() {
void SonarWebSocketImpl::reconnect() {
folly::makeFuture()
.via(worker_->getEventBase())
.delayed(std::chrono::seconds(reconnectIntervalSeconds))
.delayedUnsafe(std::chrono::seconds(reconnectIntervalSeconds))
.then([this]() { startSync(); });
}