WinHugs, bugglet fix
Neil Mitchell <[email protected]>
| Newsgroups | gmane.comp.lang.haskell.cvs.hugs |
|---|---|
| Message-ID | <[email protected]> |
Hi, There was a minor bugglet, not necessarily causing issues but certainly wrong. Its allocating an array with malloc(sizeof(Item) * Number), but Item accidentally refers to some totally unrelated structure because of a typo. Thanks Neil _______________________________________________ Cvs-hugs mailing list [email protected] http://www.haskell.org/mailman/listinfo/cvs-hugs
DlgMain.c.patch
(application/octet-stream, 638 B)
Index: src/winhugs/DlgMain.c
===================================================================
RCS file: /cvs/hugs98/src/winhugs/DlgMain.c,v
retrieving revision 1.10
diff -u -r1.10 DlgMain.c
--- src/winhugs/DlgMain.c 8 Sep 2005 16:17:49 -0000 1.10
+++ src/winhugs/DlgMain.c 14 Sep 2005 10:07:12 -0000
@@ -63,7 +63,7 @@
for (AnyButtons = 0; Buttons[AnyButtons] != 0; AnyButtons++)
; // no code required
- TbButtons = malloc(sizeof(Buttons) * AnyButtons);
+ TbButtons = malloc(sizeof(TBBUTTON) * AnyButtons);
for (i = 0; i < AnyButtons; i++) {
if (Buttons[i] == -1) {
TbButtons[i].iBitmap = 0;