Home > Software engineering >  In the MFC window domoal many times after the collapse
In the MFC window domoal many times after the collapse

Time:09-27

As title, MFC novice, encounter a problem in project, using autoit automatic testing found that after the same step of continuous operation for many times, found an error in domoal above,,,,,,, have a great god help me solve the,,,,

CodePudding user response:

Will the dialog displays too frequently, after opening, have to close the dialog, then open again

CodePudding user response:

No code on where to look out the

CodePudding user response:

DoModal is itself a blocking operation, how many times you operate

CodePudding user response:

One way to check whether resource leaks:
In the process of the task manager to see inside the column selection: memory, virtual memory size, handle number, number of threads, the USER object, GDI objects
Make your program (process) don't quit, cycle through main process many times, the more the better, like 1000000 times or even an infinite loop, record the above numerical, it through at least one hour, as long as possible, such as a month, to record more than the value, if the above two groups of numerical differential is bigger or increasing over time, will certainly have a corresponding resources resource leaks!

Search "GDI leak detection"

CodePudding user response:

CodePudding user response:

CodePudding user response:

General collapse is a null pointer or resource occupied, look at the program

CodePudding user response:

Is your automated tests, in the back of the DoModal, not closing out in front of the window?
In addition you doing in this window? If an empty window DoModal out there will be the problem?

CodePudding user response:

DoModal is itself a blocking operation, a DoModal not over yet, how can you DoModal again?
  • Related