Boost logo

Boost Users :

From: Mark Sizer (yg-boost-users_at_[hidden])
Date: 2003-06-16 13:03:38


It seems likely that it's not finding the regex DLL.

Remember that services start in a different environment than user
processes. It's possible, probable in fact, that the paths are different.

As a quick check, copy the regex dll to the system directory (usually
C:\WINNT\system32). If the service then starts, you know the problem and
can figure out a better solution (what that is depends a lot on your
situation).

My personal favorite solution: Add "." at the start of the system path
and put the DLLs in the same directory as the service.

- Mark

Koss, Loren wrote:

> Okay, I now know how to attach to a process - cool! Thanks for that..
> However, it looks like when I comment out the following:
>
>
>
> Regex expression(strMask);
>
>
>
> The service can start and I can attach and run through it, but if I
> uncomment it (which is what I need to do), essentially it IMMEDIATELY fails
> with a ERROR 1053: The service did not respond to the start or control
> request in a timely fashion. Is it possible that its not finding the proper
> libraries or a permissions problem is happening?
>
>
>
> Thanks
>
> Loren
>
>
>
> -----Original Message-----
> From: Mark Sizer [mailto:yg-boost-users_at_[hidden]]
> Sent: Saturday, June 14, 2003 6:48 PM
> To: boost-users_at_[hidden]
> Subject: [Boost-Users] Re: Regex in a service..
>
>
>
> Yes, you can debug it. After starting the service, open the Task Manager
> and get the process ID. Then type "msdev -p <pid>" on a command line.
>
> If the error happens too quickly (e.g. on startup), put an infinite loop
> at the very start and break out of it with the debugger.
>
> int i=1;
> while (i > 0 );
>
> is my favorite. Just change i to zero and everything starts going as
> normal (just don't forget to take it out!).
>
> Good Luck,
> - Mark
>
> P.S. I'm using regex in a service and it's working fine (at least I
> assume it is, nothing noticably bad has happened). MSVC 6, boost_1_30_0,
> W2K AS and W2K Pro.
>
> Koss, Loren wrote:
>
>
>>John,
>>
>>Thanks for the response. How do you deal with breakpoints within a
>>
> service?
>
>>I'm compiling then starting the service from the service control manager.
>>Will I still be able to debug it?
>>
>
>
>>>I seem to be having a difficult time using the Regex class in a
>>>service. It works wonderfully in a regular app. Can anyone help me
>>>out.. Basically, instantiating a regex class raises an exception.
>>>Any thoughts?
>>>
>>>
>>Not unless you can tell me what exception and where - if you're using the
>>
> vc
>
>>ide then set it to break on OS and C++ exceptions.
>>
>>John.
>>
>
>
>
>
>
>
>
>
> Yahoo! Groups Sponsor
>
>
>
>
>
>
>
>
> <http://us.adserver.yahoo.com/l?M=247865.3425083.4707139.1261774/D=egroupmai
> l/S=:HM/A=1482387/rand=217687422>
>
>
> Info: <http://www.boost.org <http://www.boost.org> >
> Wiki: <http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl
> <http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl> >
> Unsubscribe: <mailto:boost-users-unsubscribe_at_[hidden]>
>
>
> Your use of Yahoo! Groups is subject to the Yahoo!
> <http://docs.yahoo.com/info/terms/> Terms of Service.
>
>
>
> [Non-text portions of this message have been removed]
>
>
>
> Info: <http://www.boost.org>
> Wiki: <http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl>
> Unsubscribe: <mailto:boost-users-unsubscribe_at_[hidden]>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>
>


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net