8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 18:43:03 +01:00

Fix ,silence non initialized warnings

This commit is contained in:
brodsom 2004-08-26 23:27:46 +00:00
parent f20c5a1d96
commit aaaddf7642
4 changed files with 17 additions and 11 deletions

View File

@ -327,7 +327,7 @@ THREAD_ENTRY_DECLARE process_connection_thread(THREAD_ENTRY_PARAM arg)
* Functional description
*
**************************************/
void *thread;
void *thread = NULL; // silence non initialized warning
if (!(server_flag & SRVR_non_service)) {
thread = CNTL_insert_thread();
@ -351,7 +351,7 @@ static THREAD_ENTRY_DECLARE inet_connect_wait_thread(THREAD_ENTRY_PARAM)
* Functional description
*
**************************************/
void *thread;
void *thread = NULL; // silence non initialized warning
ISC_STATUS_ARRAY status_vector;
rem_port* port;
@ -383,7 +383,7 @@ static THREAD_ENTRY_DECLARE wnet_connect_wait_thread(THREAD_ENTRY_PARAM)
* Functional description
*
**************************************/
void *thread;
void *thread = NULL; // silence non initialized warning
ISC_STATUS_ARRAY status_vector;
if (!(server_flag & SRVR_non_service)) {
@ -425,7 +425,7 @@ static THREAD_ENTRY_DECLARE ipc_connect_wait_thread(THREAD_ENTRY_PARAM)
* Functional description
*
**************************************/
void *thread;
void *thread = NULL; // silence non initialized warning
if (!(server_flag & SRVR_non_service))
thread = CNTL_insert_thread();
@ -455,7 +455,7 @@ static THREAD_ENTRY_DECLARE xnet_connect_wait_thread(THREAD_ENTRY_PARAM)
* Starts xnet server side interprocess thread
*
**************************************/
void *thread;
void *thread = NULL; // silence non initialized warning
if (!(server_flag & SRVR_non_service))
thread = CNTL_insert_thread();

View File

@ -661,7 +661,7 @@ void REMOTE_save_status_strings( ISC_STATUS* vector)
}
TEXT* p;
USHORT l;
USHORT l = 0; // silence non initialized warning
while (*vector)
{
const ISC_STATUS status = *vector++;

View File

@ -554,9 +554,10 @@ static bool accept_connection(rem_port* port,
* Process a connect packet.
*
**************************************/
P_ARCH architecture;
USHORT version, type;
P_ARCH architecture = arch_generic;
USHORT version = 0;
USHORT type = 0;
bool accepted = false;
/* Accept the physical connection */
send->p_operation = op_reject;
@ -591,6 +592,7 @@ static bool accept_connection(rem_port* port,
protocol->p_cnct_architecture == ARCHITECTURE) &&
protocol->p_cnct_weight >= weight)
{
accepted = true;
weight = protocol->p_cnct_weight;
version = protocol->p_cnct_version;
architecture = protocol->p_cnct_architecture;
@ -600,7 +602,9 @@ static bool accept_connection(rem_port* port,
}
/* Send off out gracious acceptance or flag rejection */
if (!accepted) {
return false;
}
accept->p_acpt_version = port->port_protocol = version;
accept->p_acpt_architecture = architecture;
accept->p_acpt_type = type;
@ -4642,8 +4646,8 @@ static THREAD_ENTRY_DECLARE loopThread(THREAD_ENTRY_PARAM flags)
ISC_enter(); /* Setup floating point exception handler once and for all. */
#endif
SCHAR* thread;
#ifdef WIN_NT
SCHAR* thread = NULL; // silence non initialized warning
if (!((SLONG) flags & SRVR_non_service))
thread = reinterpret_cast<SCHAR*>(CNTL_insert_thread());
#endif

View File

@ -2579,6 +2579,7 @@ void XNET_srv(USHORT flag)
}
else {
XNET_LOG_ERROR("xnet_get_free_slot() failed");
return;
}
if (xpm && port) {
@ -2588,6 +2589,7 @@ void XNET_srv(USHORT flag)
}
else {
XNET_LOG_ERROR("failed to allocate server port for communication");
return;
}
SetEvent(xnet_response_event);