mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-23 22:03:03 +01:00
Cleanup.
This commit is contained in:
parent
64f7b17755
commit
ec27d021fd
@ -164,7 +164,7 @@ void CNTL_shutdown_service(const TEXT* message)
|
|||||||
*
|
*
|
||||||
**************************************/
|
**************************************/
|
||||||
const char* strings[2];
|
const char* strings[2];
|
||||||
char buffer[256];
|
char buffer[BUFFER_SMALL];
|
||||||
|
|
||||||
sprintf(buffer, "%s error: %lu", service_name, GetLastError());
|
sprintf(buffer, "%s error: %lu", service_name, GetLastError());
|
||||||
|
|
||||||
|
@ -87,16 +87,16 @@ class SyslogAccess iSyslogAccess;
|
|||||||
|
|
||||||
namespace Firebird {
|
namespace Firebird {
|
||||||
void Syslog::Record(Severity level, Firebird::string Msg) {
|
void Syslog::Record(Severity level, Firebird::string Msg) {
|
||||||
WORD wType = EVENTLOG_ERROR_TYPE;
|
WORD wType = EVENTLOG_ERROR_TYPE;
|
||||||
switch (level) {
|
switch (level) {
|
||||||
case Warning:
|
case Warning:
|
||||||
wType = EVENTLOG_INFORMATION_TYPE;
|
wType = EVENTLOG_INFORMATION_TYPE;
|
||||||
break;
|
break;
|
||||||
case Error:
|
case Error:
|
||||||
default:
|
default:
|
||||||
wType = EVENTLOG_ERROR_TYPE;
|
wType = EVENTLOG_ERROR_TYPE;
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
|
iSyslogAccess.Record(wType, Msg);
|
||||||
}
|
}
|
||||||
iSyslogAccess.Record(wType, Msg);
|
|
||||||
}
|
|
||||||
} // namespace Firebird
|
} // namespace Firebird
|
||||||
|
@ -234,10 +234,10 @@ void CNTL_shutdown_service( const TEXT* message)
|
|||||||
**************************************/
|
**************************************/
|
||||||
const char* strings[2];
|
const char* strings[2];
|
||||||
|
|
||||||
char buffer[256];
|
char buffer[BUFFER_SMALL];
|
||||||
sprintf(buffer, "%s error: %lu", "Firebird Server", GetLastError());
|
sprintf(buffer, "%s error: %lu", REMOTE_SERVICE, GetLastError());
|
||||||
|
|
||||||
HANDLE event_source = RegisterEventSource(NULL, "Firebird Server");
|
HANDLE event_source = RegisterEventSource(NULL, REMOTE_SERVICE);
|
||||||
if (event_source) {
|
if (event_source) {
|
||||||
strings[0] = buffer;
|
strings[0] = buffer;
|
||||||
strings[1] = message;
|
strings[1] = message;
|
||||||
|
Loading…
Reference in New Issue
Block a user