comparison dwtest.c @ 1319:03f0bc85e7be

Code change to fix llvm-gcc optimization problem on Mac. long/int size difference in 64bit causing unexpected buffer overrun with optimization.
author bsmith@81767d24-ef19-dc11-ae90-00e081727c95
date Sat, 05 Nov 2011 21:32:35 +0000
parents dbd507f42947
children d4c874f13e9b
comparison
equal deleted inserted replaced
1318:ebd67be26f43 1319:03f0bc85e7be
1083 DW_CFA_TIME | DW_CFA_CENTER | DW_CFA_HORZSEPARATOR | DW_CFA_SEPARATOR, 1083 DW_CFA_TIME | DW_CFA_CENTER | DW_CFA_HORZSEPARATOR | DW_CFA_SEPARATOR,
1084 DW_CFA_DATE | DW_CFA_LEFT | DW_CFA_HORZSEPARATOR | DW_CFA_SEPARATOR }; 1084 DW_CFA_DATE | DW_CFA_LEFT | DW_CFA_HORZSEPARATOR | DW_CFA_SEPARATOR };
1085 int z; 1085 int z;
1086 CTIME time; 1086 CTIME time;
1087 CDATE date; 1087 CDATE date;
1088 unsigned long size; 1088 unsigned long size, newpoint;
1089 HICN thisicon; 1089 HICN thisicon;
1090 1090
1091 /* create a box to pack into the notebook page */ 1091 /* create a box to pack into the notebook page */
1092 containerbox = dw_box_new(BOXHORZ, 2); 1092 containerbox = dw_box_new(BOXHORZ, 2);
1093 dw_box_pack_start( notebookbox4, containerbox, 500, 200, TRUE, TRUE, 0); 1093 dw_box_pack_start( notebookbox4, containerbox, 500, 200, TRUE, TRUE, 0);
1159 mle_point = dw_mle_import(container_mle, buffer, mle_point); 1159 mle_point = dw_mle_import(container_mle, buffer, mle_point);
1160 sprintf(buffer, "[%d]abczxydefijkl", mle_point); 1160 sprintf(buffer, "[%d]abczxydefijkl", mle_point);
1161 mle_point = dw_mle_import(container_mle, buffer, mle_point); 1161 mle_point = dw_mle_import(container_mle, buffer, mle_point);
1162 dw_mle_delete(container_mle, 9, 3); 1162 dw_mle_delete(container_mle, 9, 3);
1163 mle_point = dw_mle_import(container_mle, "gh", 12); 1163 mle_point = dw_mle_import(container_mle, "gh", 12);
1164 dw_mle_get_size(container_mle, (unsigned long*)&mle_point, NULL); 1164 dw_mle_get_size(container_mle, &newpoint, NULL);
1165 mle_point = (int)newpoint;
1165 sprintf(buffer, "[%d]\r\n\r\n", mle_point); 1166 sprintf(buffer, "[%d]\r\n\r\n", mle_point);
1166 mle_point = dw_mle_import(container_mle, buffer, mle_point); 1167 mle_point = dw_mle_import(container_mle, buffer, mle_point);
1167 dw_mle_set_cursor(container_mle, mle_point); 1168 dw_mle_set_cursor(container_mle, mle_point);
1168 /* connect our event trappers... */ 1169 /* connect our event trappers... */
1169 dw_signal_connect(container, DW_SIGNAL_ITEM_ENTER, DW_SIGNAL_FUNC(item_enter_cb), (void *)container_status); 1170 dw_signal_connect(container, DW_SIGNAL_ITEM_ENTER, DW_SIGNAL_FUNC(item_enter_cb), (void *)container_status);