"--name" argument makes any wx-program use 100% CPU

Emil Gustafsson Tutus emil at tutus.se
Sun Feb 18 23:57:42 PST 2007


Last week working with wxPython 2.8.1.1 (using wxWodgets 2.8.1.1) I
stumbled across a problem I have boiled down to be a wxWidget problem
rather than a wxPython problem. I ran into this problem upgrading from
wxGTK 2.4 to wxGTK 2.8.

I use Ubuntu 6.06 and wxWidgets 2.8.1.1 (wxGTK) and I can reproduce the
problem with any of the WX-samples (well I have not tried all, but a few,
for example the notebook sample). I have not had the privilige to test
this with any other plattform.

Assuming the notebook sample:
Starting with:
./notebook --name foo
or
./notebook foo --name bar
starts the application as expected. Starting with:
./notebook --name foo bar
starts the application using 100% CPU *before* the MyApp::OnInit is called
and hence no application window is made visible.

I have made quite a few tests and the only common criteria for reproducing
this bug is that if I use an argument "--name" anywhere on the command
line the application will not start if it is followd by *more* than one
argument. And it is only "--name" that does not work. More examples that
work:
./notebook -name foo bar
./notebook a bunch of args --name foo
./notebook --name2 foo bar

I have not managed to find anything in the wx-source searching for name or
--name that explain this behaviour. Nor have I found anyone with similar
problems searching in mail-lists/forums.

Is this a known problem?
Can anyone reproduce this on the same/other platforms?
What to do except stop using --name?

regards
/E





More information about the wx-users mailing list