Example #1
0
void socketmanager::RetryConn(std::unique_ptr<mcurlconn> cs) {
	if (cs->mcflags & mcurlconn::MCF::IN_RETRY_QUEUE) {
		LogMsgFormat(LOGT::SOCKERR, "socketmanager::RetryConn: Attempt to add mcurlconn to retry queue which is marked as already in queue, this is a bug: type: %s, conn ID: %d, url: %s",
				cstr(cs->GetConnTypeName()), cs->id, cstr(cs->url));
		return;
	}

	cs->mcflags |= mcurlconn::MCF::IN_RETRY_QUEUE;
	cs->AddToRetryQueueNotify();
	retry_conns.push_back(std::move(cs));
	RetryConnLater();
}