troubleshooting Question

What happens to WM_TIMER events from SetTimer when they are not handled?

Avatar of charles_gilley
charles_gilley asked on
System Programming
7 Comments1 Solution681 ViewsLast Modified:
Curiosity question - suppose I have a dialog that draws something in response to an WM_TIMER event.
In the OnInitDialog method, I call SetTimer(nTimer, 1, NULL); for a 1mSec update.  It doesn't matter that
the interval is not predictable, what does matter is that the time spent in OnTimer is >> than the timer
interval (meaning WM_TIMER events should be piling up).

Does mfc or Windows or the message pump have any built in protection to deal with this situation?
I have heard it alleged that the events will leak memory, but I am dubious of this allegation.

Thanks for any insights...
Freelance programmer / Consultant

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 7 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 7 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros