Print Page | Close Window

Divide by zero in GetStretchIconSize

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=20573
Printed Date: 06 May 2024 at 5:35am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Divide by zero in GetStretchIconSize
Posted By: rdhd
Subject: Divide by zero in GetStretchIconSize
Date Posted: 01 February 2013 at 5:40pm
I don't know how this occurred by I have a dump file from a customer that shows GetStretchIconSize, being called from DrawControlToolBarParent generating a divide by zero runtime exception.

Looks like it is the line that divides the width by the height (pImage->GetHeight).

It might be prudent to examine that code and handle the situation where either the Width() or Height() functions return zero.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net