8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 22:03:03 +01:00
This commit is contained in:
asfernandes 2008-10-09 00:59:56 +00:00
parent d9e1ba9da5
commit ac600b29d7
4 changed files with 11 additions and 9 deletions

View File

@ -269,7 +269,7 @@ static HANDLE forkEvent = INVALID_HANDLE_VALUE;
static bool forkThreadStarted = false;
typedef Firebird::Array<SOCKET> SocketsArray;
static SocketsArray *forkSockets;
static SocketsArray* forkSockets;
#endif
@ -781,7 +781,7 @@ rem_port* INET_connect(const TEXT* name,
n = connect((SOCKET) port->port_handle,
(struct sockaddr *) &address, sizeof(address));
inetErrNo = INET_ERRNO;
if (n != -1 && send_full(port, packet))
return port;
}
@ -1235,7 +1235,8 @@ static rem_port* alloc_port( rem_port* parent)
static WSADATA wsadata;
const WORD version = MAKEWORD(2, 0);
const int wsaError = WSAStartup(version, &wsadata);
if (wsaError) {
if (wsaError)
{
if (parent)
inet_error(parent, "WSAStartup", isc_net_init_error, wsaError);
else {
@ -1870,9 +1871,9 @@ THREAD_ENTRY_DECLARE forkThread(THREAD_ENTRY_PARAM arg)
while (!INET_shutting_down)
{
SOCKET s = 0;
{
{ // scope
Firebird::MutexLockGuard forkGuard(forkMutex);
if (!forkSockets || forkSockets->getCount() == 0)
break;

View File

@ -44,8 +44,8 @@ Firebird::AtomicCounter rem_port::portCounter = 0;
IMPLEMENT_TRACE_ROUTINE(remote_trace, "REMOTE")
#endif
const SLONG DUMMY_INTERVAL = 60; /* seconds */
const int ATTACH_FAILURE_SPACE = 16 * 1024; /* bytes */
const SLONG DUMMY_INTERVAL = 60; // seconds
const int ATTACH_FAILURE_SPACE = 16 * 1024; // bytes
static Firebird::StringsBuffer* attachFailures = NULL;
static Firebird::GlobalPtr<Firebird::Mutex> attachFailuresMutex;

View File

@ -5448,7 +5448,7 @@ void Worker::shutdown()
{
THREAD_SLEEP(100);
}
catch(const Firebird::Exception&)
catch (const Firebird::Exception&)
{
m_mutex->enter();
throw;

View File

@ -2272,7 +2272,8 @@ static XPM get_free_slot(ULONG* map_num, ULONG* slot_num, ULONG* timestamp)
break;
}
if (free_slot < global_slots_per_map) {
if (free_slot < global_slots_per_map)
{
xpm->xpm_count++;
xpm->xpm_ids[free_slot] = XPM_BUSY;
free_map = xpm->xpm_number;