removed more tabs

This commit is contained in:
Emiel Bruijntjes 2018-03-06 08:45:12 +01:00
parent 69596e49dc
commit 5b8841c937
3 changed files with 10 additions and 7 deletions

View File

@ -67,9 +67,12 @@ public:
const char *last = data + size;
// must start with ampqs:// to have a secure connection (and we also assign a different default port)
if ((_secure = strncmp(data, "amqps://", 8) == 0)) _port = 5671;
_secure = strncmp(data, "amqps://", 8) == 0;
// otherwise protocol must be amqp://
// default port changes for secure connections
if (_secure) _port = 5671;
// otherwise protocol must be amqp://
else if (strncmp(data, "amqp://", 7) != 0) throw std::runtime_error("AMQP address should start with \"amqp://\" or \"amqps://\"");
// begin of the string was parsed
@ -142,7 +145,7 @@ public:
* @param port
* @param login
* @param vhost
* @param secure
* @param secure
*/
Address(std::string host, uint16_t port, Login login, std::string vhost, bool secure = false) :
_secure(secure),

View File

@ -58,7 +58,7 @@
#include <winsock2.h>
#pragma comment(lib,"Ws2_32.lib")
//# include <sys/param.h>
//# include <sys/param.h>
#if BYTE_ORDER == LITTLE_ENDIAN

View File

@ -176,7 +176,7 @@ protected:
TcpConnection *const connection,
const int fd)
{
// Resolve any potential problems with dangling pointers
// Resolve any potential problems with dangling pointers
// (remember we are using async).
const std::shared_ptr<Watcher> apWatcher = awpWatcher.lock();
if (!apWatcher) { return; }
@ -210,7 +210,7 @@ protected:
TcpConnection *const connection,
const int fd)
{
// Resolve any potential problems with dangling pointers
// Resolve any potential problems with dangling pointers
// (remember we are using async).
const std::shared_ptr<Watcher> apWatcher = awpWatcher.lock();
if (!apWatcher) { return; }
@ -498,7 +498,7 @@ protected:
// construct a new pair (watcher/timer), and put it in the map
const std::shared_ptr<Watcher> apWatcher =
std::make_shared<Watcher>(_ioservice, _strand, fd);
std::make_shared<Watcher>(_ioservice, _strand, fd);
_watchers[fd] = apWatcher;