face: Avoid resuming transport after connect if the transmission queue empty
Change-Id: I53763b62a8fc12d1d2613daa8d4f9d2b5109b7aa
Refs: #3957
diff --git a/src/transport/stream-transport-impl.hpp b/src/transport/stream-transport-impl.hpp
index d542741..c2dab39 100644
--- a/src/transport/stream-transport-impl.hpp
+++ b/src/transport/stream-transport-impl.hpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/**
- * Copyright (c) 2013-2016 Regents of the University of California.
+ * Copyright (c) 2013-2017 Regents of the University of California.
*
* This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
*
@@ -132,10 +132,10 @@
m_connectTimer.cancel();
if (!error) {
- resume();
m_transport.m_isConnected = true;
if (!m_transmissionQueue.empty()) {
+ resume();
asyncWrite();
}
}