| От | Laurent Ballester |
|---|---|
| Тема | Re: Postmaster service code |
| Дата | |
| Msg-id | 00e001c435b3$492f9610$1cf0fdc1@fleche обсуждение исходный текст |
| Ответ на | Postmaster service code ("Dave Page" <dpage@vale-housing.co.uk>) |
| Список | pgsql-hackers-win32 |
Yes, we need to create and register a tiny DLL to avoid to have error message joined to our log message such as describe Dave in it's previous mail. By studing the works made by Claudio, a simple way to achieve this work it to create a message wich contains only %1 like the mc file i'am attached with this post, and to modify a little bit the write_eventlog function he made (4 parameters of ReportEvent have to change to 0 with 0x00000001L or PGWIN32_EVENTLOG_MSG in my sample). To obtain a DLL, we need Microsoft MC Compiler to create a RC file and after we can finish the compilation with Msys tools. for Visual Studio users : mc EventLogMsg.mc # produce one rc file and one .h file rc -r -fo EventLogMsg.res EventLogMsg.rc link -dd -noentry -out:EventLogMsg.dll EventLogMsg.res for Msys : After obtain a .RC file with MC compiler windres -o EventLogMsg.o EventLogMsg.rc dllwrap --dllname=EventLogMsg.dll --driver-name=gcc EventLogMsg.o To finish, we have to register the DLL in HKEY_LOCAL_MACHINE\system\CurrentControlSet\Services\EventLog\Application Create a entry name PostGreSQL, add a key EventMessageFile set it with the full path of the DLL two issues : made this job by setup program or by write_eventlog() itself. Do you know, where will be the right place to put these files and update/create a Makefile Regards, Laurent
В списке pgsql-hackers-win32 по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера