HI!
Timothy Wall wrote:
You might try instrumenting native/callback.c:callback_dispatch with a
call to SetServiceStatus to see if that code is being reached.
There are two possible failure modes if callback_dispatch *is* entered.
One if the callback has been GC'd (which it apparently is not), and one
if the callback can't attach itself to the VM (which results in output
to stderr).
Thanks for the insight.
I tried putting some fprintf(stderr...) in several places in the JNA
native code, but nothing appeared on stderr. I also tried to do fopen()
and write to some file and nothing again.
Also my machine froze several times while compiling the native code with
NB 5.5.1 and cygwin gc++... So, I gave up on that.
If callback_dispatch is never called, then something must be wrong at
either the service or the libffi layers.
In desperation, I moved everything to a Windows Server 2003 machine and
there the ServiceControl callback works!
So, the fact that one Callback is called and the 2nd not must have
something to do with Windows Vista!
Thomas