[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [TSVN] Tortoiseproc apparently must have a shell

From: Norbert Unterberg <nunterberg_at_gmail.com>
Date: 2005-06-23 13:22:55 CEST

2005/6/23, Thomas Denk <thomas.denk@gmail.com>:

> Anyway, it seems more likely that something is amiss in the 500 lines of
> code that make up wxExecute than in the two lines above. So since I am
> bound to use wx, I guess I'll live with the "cmd hack", after all, it
> works :-)

There is something that might have to do with it:

When you execute an application, at least the the WinExec system call
returns as soon as the started process has called the GetMessage
function (or after some timeout). That means that WinExec returns for
windows MFC applications usually after their InitInstance is complete,
or if they call a message box (the message box code calls GetMessage
internally). So message boxes can can make a difference here. And
calling CMD /c some_app makes a difference here because it does not
return before some_app has finished. You can see the difference:
run CMD
in CMD, compare "notepad" to "cmd /c notepad". See the difference?

However, CreateProcess is used here that does not depend on that, but
maybe some of the code after the CreateProcess tries to mimic WinExec
here? Maybe it even kills the process when it does not "respond" in
some time? Note that TortoiseProc may do some lengthy repository
operation before calling GetMessage for the first time?

Steve, how about calling a single GetMessage in the InitInstance()
method, just for test?

One other difference:
CreateProcess has a flag to indicate if the environment should be in
unicode or not. TSVN 1.2 is a unicode build, but the
CREATE_UNICODE_ENVIRONMENT does not seem to be set. Can this be a
problem here?

Norbert

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tortoisesvn.tigris.org
For additional commands, e-mail: dev-help@tortoisesvn.tigris.org
Received on Thu Jun 23 13:23:13 2005

This is an archived mail posted to the TortoiseSVN Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.