8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 22:03:03 +01:00
This commit is contained in:
dimitr 2005-08-31 16:08:14 +00:00
parent 64f7b17755
commit ec27d021fd
3 changed files with 15 additions and 15 deletions

View File

@ -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());

View File

@ -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

View File

@ -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;