Re: Getting Win32 Error Codes 997 and 288




Thanks alot Chris for helping me out. Let me describe it further more.

I am using Threads to handle all the data coming from win32 callbacks.
Previouse I was utilizing the Thread Pool thread but whenever I try to
create an array or Database Connection or in case of exception raised then
the win32 dll stops firing the callback. For getting rid of that problem I
introduced threads in the Windows Service, These threads are initialized at
the startup of the service but after that Error 288 is coming on the startup
of the Windows Service. I suspect that there is something I am doing wrong
with the thread locking (Although at the moment I didn't indroduced any
locking mechanism, just creating two threads to manage audio data and
insertion in database). Any hint which will be helpful for me will be highly
appreciated.

Regards
Fiaz

"Chris P." <msdn@xxxxxxxxxxxx> wrote in message
news:15i8nmj9oxv7y.6v70e1p209fs$.dlg@xxxxxxxxxxxxx
On Fri, 1 Aug 2008 17:49:51 +0500, msnews.microsoft.com wrote:

First of all I would like to thank you for your reply. Its a windows
service
which receives callbacks from a win32 dll. There are two threads
initialized
when service starts. Basically the win32 dll is supplied with a card
which
posts the data and voice of any phone call through different callback
functions. Whenever this service starts and I query the GetLastError() of
kernal32 dll then it always gives the 997 error in the windows service
constructor and 288 error in Windows Service OnStart Event.

I just realized that 997 was familiar to me. That is ERROR_IO_PENDING and
I also receive it in my service startup after calling StartService() so I
think this is ok.

Error 288 is ERROR_NOT_OWNER "Attempt to release mutex not owned by
caller.". So that one is a bug on your part.

--
http://www.chrisnet.net/code.htm
[MS MVP for DirectShow / MediaFoundation]


.



Relevant Pages

  • Re: Getting Win32 Error Codes 997 and 288
    ... I am using third party win32 dll to get the callbacks. ... introduced threads in the Windows Service, ...
    (microsoft.public.win32.programmer.mmedia)
  • Re: Getting Win32 Error Codes 997 and 288
    ... which receives callbacks from a win32 dll. ... kernal32 dll then it always gives the 997 error in the windows service ...
    (microsoft.public.win32.programmer.mmedia)
  • Re: Getting Win32 Error Codes 997 and 288
    ... which receives callbacks from a win32 dll. ... posts the data and voice of any phone call through different callback ... constructor and 288 error in Windows Service OnStart Event. ...
    (microsoft.public.win32.programmer.mmedia)
  • RE: Specifying A Service Specific Error...
    ... Win32 SetServiceStatus call to specify the service specific exit code. ... .net Windows Service application. ... Microsoft Online Community Support ... Microsoft Customer Support Services at ...
    (microsoft.public.dotnet.general)
  • Passing struct of virtual functions
    ... I have a native win32 C++ DLL that has exported functions (I can't modify the ... I'm trying to call this exported win32 DLL function from C#. ... The C struct look something like this ... struct ExportFuncs{ ...
    (microsoft.public.dotnet.languages.csharp)

Loading