You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by Holger Floerke <fl...@doctronic.de> on 2002/10/03 09:31:29 UTC

Xalan-C++ 1.3 in w2k system service

Hi there,

   first I wanted to post a bug, but now I am not sure what happens and I 
have to do some tests...

   There is a w2k system service using XalanTransformer. If I start the 
service (running under the 'system' account), all other programs using 
XalanTransformer executed by the current user won't start (I have to find 
out the exact exception, but I think they are not able to initialize). If I 
stop the service, the programs work. If I start the program first and then 
start the service, both work. If I start the service under the current 
users account, both work.

   Any idea? Maybe some access problems with shared memory during 
initialization? If nobody says I am wrong, I will post a bug with two 
sample programs.

TIA,

HolgeR

-- 
holger floerke                     d  o  c  t  r  o  n  i  c
email floerke@doctronic.de         information publishing + retrieval
phone +49 2222 9292 90             http://www.doctronic.de


RE: Xalan-C++ 1.3 in w2k system service

Posted by Holger Floerke <fl...@doctronic.de>.
>AFAICT Xalan doesn't use shared memory.  Presumably this is something that
>your apps/service are doing?
I don't use shared memory, too...but I am using semaphores...damn...my fault.

Thanx!

HolgeR

-- 
holger floerke                     d  o  c  t  r  o  n  i  c
email floerke@doctronic.de         information publishing + retrieval
phone +49 2222 9292 90             http://www.doctronic.de


RE: Xalan-C++ 1.3 in w2k system service

Posted by Mark Weaver <ma...@npsl.co.uk>.
AFAICT Xalan doesn't use shared memory.  Presumably this is something that
your apps/service are doing?

If this is the case, what's mucking you up will most likely be the security
on the shared memory section you have created.  A simple solution is to
create the section with a NULL DACL:

   SECURITY_DESCRIPTOR sd;
   InitializeSecurityDescriptor(&sd, SECURITY_DESCRIPTOR_REVISION);
   SetSecurityDescriptorDacl(&sd, TRUE, NULL, FALSE);

   SECURITY_ATTRIBUTES sa;
   sa.nLength = sizeof(SECURITY_ATTRIBUTES);
   sa.bInheritHandle = FALSE;
   sa.lpSecurityDescriptor = &sd;

and pass sa to CreateFileMapping, plus similarly for any other shared kernel
objects.  What you are describing sounds exactly like what would happen if
you simply passed NULL for the security descriptor.

Mark

> -----Original Message-----
> From: Holger Floerke [mailto:floerke@doctronic.de]
> Sent: 03 October 2002 08:31
> To: xalan-dev@xml.apache.org
> Subject: Xalan-C++ 1.3 in w2k system service
>
>
> Hi there,
>
>    first I wanted to post a bug, but now I am not sure what happens and I
> have to do some tests...
>
>    There is a w2k system service using XalanTransformer. If I start the
> service (running under the 'system' account), all other programs using
> XalanTransformer executed by the current user won't start (I have to find
> out the exact exception, but I think they are not able to
> initialize). If I
> stop the service, the programs work. If I start the program first
> and then
> start the service, both work. If I start the service under the current
> users account, both work.
>
>    Any idea? Maybe some access problems with shared memory during
> initialization? If nobody says I am wrong, I will post a bug with two
> sample programs.
>
> TIA,
>
> HolgeR
>
> --
> holger floerke                     d  o  c  t  r  o  n  i  c
> email floerke@doctronic.de         information publishing + retrieval
> phone +49 2222 9292 90             http://www.doctronic.de
>
>