aboutsummaryrefslogtreecommitdiff
path: root/nxcomp
diff options
context:
space:
mode:
authorVadim Troshchinskiy <vtroshchinskiy@qindel.com>2017-03-16 12:55:18 +0100
committerMihai Moldovan <ionic@ionic.de>2017-10-27 09:01:44 +0200
commitf855b3b614cd9de8e55699141798e6038db36fd6 (patch)
treef2548b45e0ebb15287ead223a61dc66262289292 /nxcomp
parent1cf6aa8f28b971853e77125b92894d286cc0b203 (diff)
downloadnx-libs-f855b3b614cd9de8e55699141798e6038db36fd6.tar.gz
nx-libs-f855b3b614cd9de8e55699141798e6038db36fd6.tar.bz2
nx-libs-f855b3b614cd9de8e55699141798e6038db36fd6.zip
Fix whitespace and line splitting issues reported by ionic
Diffstat (limited to 'nxcomp')
-rw-r--r--nxcomp/src/Loop.cpp29
1 files changed, 19 insertions, 10 deletions
diff --git a/nxcomp/src/Loop.cpp b/nxcomp/src/Loop.cpp
index 38d411232..114bf9709 100644
--- a/nxcomp/src/Loop.cpp
+++ b/nxcomp/src/Loop.cpp
@@ -661,10 +661,11 @@ static void handleCheckSessionInLoop();
static void handleCheckBitrateInLoop();
static void handleCheckSelectInLoop(int &setFDs, fd_set &readSet,
- fd_set &writeSet, T_timestamp selectTs);static void handleCheckResultInLoop(int &resultFDs, int &errorFDs, int &setFDs, fd_set &readSet,
+ fd_set &writeSet, T_timestamp selectTs);
+static void handleCheckResultInLoop(int &resultFDs, int &errorFDs, int &setFDs, fd_set &readSet,
fd_set &writeSet, struct timeval &selectTs,
struct timeval &startTs);
- static void handleCheckStateInLoop(int &setFDs);
+static void handleCheckStateInLoop(int &setFDs);
static void handleCheckSessionInConnect();
static inline void handleSetReadInLoop(fd_set &readSet, int &setFDs, struct timeval &selectTs);
@@ -2529,7 +2530,8 @@ int NXTransAlert(int code, int local)
{
if (logofs == NULL)
{
- logofs = &cerr; }
+ logofs = &cerr;
+ }
nxdbg << "NXTransAlert: Can't request an alert without "
<< "a valid NX transport.\n" << std::flush;
@@ -3186,7 +3188,9 @@ int SetupProxyConnection()
nxinfo << "Loop: listenSocket is "<< ( listenSocket.enabled() ? "enabled" : "disabled") << ". "
<< "The socket URI is '"<< ( socketUri != NULL ? socketUri : "<unset>") << "'.\n" << std::flush;
- free(socketUri); socketUri = NULL;
+ free(socketUri);
+ socketUri = NULL;
+
if (WE_INITIATE_CONNECTION)
{
if (connectSocket.getSpec(&socketUri))
@@ -8555,7 +8559,7 @@ int ParseCommandLineOptions(int argc, const char **argv)
nxinfo << "Loop: Argc is " << argc << ".\n" << std::flush;
for (int argi = 0; argi < argc; argi++)
- {
+ {
nxinfo << "Loop: Argv[" << argi << "] is " << argv[argi]
<< ".\n" << std::flush;
}
@@ -13019,11 +13023,13 @@ void PrintProcessInfo()
if (*errorsFileName != '\0')
{
- cerr << "Info" << ": Using errors file '" << errorsFileName << "'.\n"; }
+ cerr << "Info" << ": Using errors file '" << errorsFileName << "'.\n";
+ }
if (*statsFileName != '\0')
{
- cerr << "Info" << ": Using stats file '" << statsFileName << "'.\n"; }
+ cerr << "Info" << ": Using stats file '" << statsFileName << "'.\n";
+ }
}
@@ -13447,7 +13453,7 @@ int ParseArg(const char *type, const char *name, const char *value)
case 'k':
case 'm':
case 'g':
- {
+ {
nxinfo << (char) toupper(*id);
break;
}
@@ -13941,8 +13947,11 @@ static void handleCheckBitrateInLoop()
static void handleCheckStateInLoop(int &setFDs)
-{
- int fdLength; int fdPending; int fdSplits;
+{
+ int fdLength;
+ int fdPending;
+ int fdSplits;
+
for (int j = 0; j < setFDs; j++)
{
if (j != proxyFD)