RB 9.01 terrible cleanup
We have a form containing all the usual RB goodies. Preview form, designer,
etc. We use this form in a DLL (i.e. the Application variable is not really
the true Application variable, it just has the correct Handle). We are
capable of compiling this unit into either the dll or the main app's exe.
With RB7.04 this scenario had no problems at all.
With RB9.01 this works 100% when the form is part of the main app, when it
is in a DLL it still partially works. But once you envoke the Designer (we
use the designer with a showmodal), close it and then try to quit the main
app (exe), i.e. when the DLL is unloaded and consequently also the units
used in the DLL, then the exe crashes. This only means one thing, units
which are part of the end-user designer does not clean up after themselves,
i.e. maybe in the finalization sections? Or even worse, they assume
variables are set and tries to free them when they might not have been
initialized.
When we reverted back to RB7.04 (without changing a single line of our
code)... everything works fine once again.
This issue is hard to debug, but we got our compiler stopped at the
finalization of the new RB9.01 partial-jedi object inspector unit,
ppJvInspector.pas, after which it crashed in the CPU window. Don't know if
this helps. But something serious has gone wrong from RB7.04 to RB9.01.
Obviously some new unit somewhere is assuming things it should not be. A
good QA checker should spot the problem even if RB9.01 is ran in an EXE, as
this surely causes a memory leak of sorts.
Regards, J
PS: A new "look" designer would not be bad idea for RB either. It still
looks as if it exists in Win95 days, i.e. 3D controls like it is at least an
8 year old interface, no adapting to XP themes etc. Really sucks when your
whole app looks funky and fit within XP, but you are forced to present your
end-users with a report designer that looks like a separate application
ported from the 1990s. On top of which, it would also be nice to be able to
create the designer in one's own panel, like the previewer, instead of being
dependent on the standalone window. At least this way one can give it a
"new look", menu, toolbar, buttons etc.
etc. We use this form in a DLL (i.e. the Application variable is not really
the true Application variable, it just has the correct Handle). We are
capable of compiling this unit into either the dll or the main app's exe.
With RB7.04 this scenario had no problems at all.
With RB9.01 this works 100% when the form is part of the main app, when it
is in a DLL it still partially works. But once you envoke the Designer (we
use the designer with a showmodal), close it and then try to quit the main
app (exe), i.e. when the DLL is unloaded and consequently also the units
used in the DLL, then the exe crashes. This only means one thing, units
which are part of the end-user designer does not clean up after themselves,
i.e. maybe in the finalization sections? Or even worse, they assume
variables are set and tries to free them when they might not have been
initialized.
When we reverted back to RB7.04 (without changing a single line of our
code)... everything works fine once again.
This issue is hard to debug, but we got our compiler stopped at the
finalization of the new RB9.01 partial-jedi object inspector unit,
ppJvInspector.pas, after which it crashed in the CPU window. Don't know if
this helps. But something serious has gone wrong from RB7.04 to RB9.01.
Obviously some new unit somewhere is assuming things it should not be. A
good QA checker should spot the problem even if RB9.01 is ran in an EXE, as
this surely causes a memory leak of sorts.
Regards, J
PS: A new "look" designer would not be bad idea for RB either. It still
looks as if it exists in Win95 days, i.e. 3D controls like it is at least an
8 year old interface, no adapting to XP themes etc. Really sucks when your
whole app looks funky and fit within XP, but you are forced to present your
end-users with a report designer that looks like a separate application
ported from the 1990s. On top of which, it would also be nice to be able to
create the designer in one's own panel, like the previewer, instead of being
dependent on the standalone window. At least this way one can give it a
"new look", menu, toolbar, buttons etc.
This discussion has been closed.
Comments
finalization clause, I have also been able to reduce this to a specific
designer action in both RB7 and RB9. When you select a component, ex a
Label in the designer, this exception also appears in RB7. The assumption
is that the new Object Inspector in RB9 does this automatically (i.e. select
the first component) and thus why it always cause the exception. It must be
noted that the exception can only be observed in Delphi, because if you run
the application standalone, the exception occurs effectively while the
application has already shutdown (or started to, i.e. while unloading loaded
dlls). Thus, although it still does not forbode well on RB's cleaning up
abilities, at least it is non-critical in the sense that end-users won't
know.
Regards, J
Thanks for the information and feedback. We will research this and get back
to you as soon as possible.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com