From: SourceForge.net <no...@so...> - 2009-02-17 20:16:31
|
Bugs item #2609641, was opened at 2009-02-17 09:19 Message generated for change (Comment added) made by miesfeld You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=684730&aid=2609641&group_id=119701 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: External Functions Group: v4.0beta Status: Open Resolution: None Priority: 5 Private: No Submitted By: Jim129 (m129asa) Assigned to: Mark Miesfeld (miesfeld) Summary: 4.0beta - Initdialog is failing Initial Comment: When I run my application on Windows Vista 64-bit, I get an error that says "Open Object Rexx Interface has stopped working". I'm attaching my application. Although it's all there, only a small part is needed to make it fail. Run TEMPD.REX which will cause the problem. It seems to fail in the InitDialog method of DAMainScreen.REX. ---------------------------------------------------------------------- >Comment By: Mark Miesfeld (miesfeld) Date: 2009-02-17 12:16 Message: I get different odd results on different systems. The reason is, in the defineDialog() method of the .Main class, there is this statement: self~CreateMenu(5) But, there are about 25 menu items added. The argument to createMenu is the maximum number of menu items to be added and the amount of memory allocated is determined by that. At least in the sample you attached, the problem is memory corruption. Only enough memory is allocated for 5 menu items. As the rest of the items are allocated they step on memory in the interpreter, causing havoc. Doing either self~CreateMenu or self~CreateMenu(55) fixes the attached sample. The default for createMenu with no arg is to allocate memory for 100 items. Really you should only specify the count argument if for some reason your menu is going to have over 100 items in it. I'll add some text to the doc to clarify that. Jim, try fixing that createMenu() call and see if it clears things up in your real program. I suspect it will. Let me know. By the way, your example works fine under 3.2.0 for me. That is just luck. ---------------------------------------------------------------------- Comment By: Mark Miesfeld (miesfeld) Date: 2009-02-17 09:26 Message: Prize for the first bug reported. I'll take a look at this today. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=684730&aid=2609641&group_id=119701 |