Thanks to this site I am learning at a fast rate, I had a head start on most of the members hear couse I have been doing assembly for over 15 year maybe more mmmm. yep more. anyway I would just like to know about how or what would happen if you closed your program and ended it without: 1. letting go of Allocated memory. 2. without stopping a thread. 3. without deleteing DC's I would think that if windows was wrote right that it would know that those handles to those resources belonged to your app. and should close them off and return the resources to the system pool, if your program ended without deleteing them properly. is this true? and this leads me to another question, if an app is shut down by windows, are those resources put back into the system pool? if not on any of the above then windows really, truely is crashware. I just wanted to know this info couse I was wanting to make a program to solve this problem if possible, also I have noticed that when Explorer crash's you lose most of your Icons in your system tray, I would like to see if I can write something to bring them back or just clear that memory back to the system pool. Anyone know anything about this?
Posted on 2001-03-10 13:46:00 by Zcoder
Here's a snippet from the ExitProcess documentation: ---snip--- Terminating a process causes the following: 1. All of the object handles opened by the process are closed. 2. All of the threads in the process terminate their execution. 3. The state of the process object becomes signaled, satisfying any threads that had been waiting for the process to terminate. 4. The states of all threads of the process become signaled, satisfying any threads that had been waiting for the threads to terminate. 5. The termination status of the process changes from STILL_ACTIVE to the exit value of the process. ---snap--- The same goes for TerminateProcess.
also I have noticed that when Explorer crash's you lose most of your Icons in your system tray, I would like to see if I can write something to bring them back or just clear that memory back to the system pool.
As the start menu and system tray are windows owned by the explorer, a new instance of it that is executed after its previous instance crashed does not "know" which icons should be displayed in the system tray (some applications notice when their icon isn't displayed in the tray anymore and re-add it).
Posted on 2001-03-10 16:02:00 by Tola
I have noticed that. You would have thought that MS would have thought about having some kind of INI for it so if this happend it could read the file to know what was on it befor a crash. it of couse would not use it at boot time. and each part of windows should of had a command line param sent to it when it was started letting it know if this is a windows start up or a reinstall from a crash. I think you get my point. MS is still the best Crashware around.
Posted on 2001-03-12 16:02:00 by Zcoder