[evolution-patches] [Fwd: Patch for memory read problem [#43119]]
- From: Ettore Perazzoli <ettore ximian com>
- To: evolution-patches ximian com
- Subject: [evolution-patches] [Fwd: Patch for memory read problem [#43119]]
- Date: 17 May 2003 17:11:42 -0400
Ooops, re-posting from the proper account.
-- Ettore
--- Begin Message ---
- From: Ettore Perazzoli <ettore perazzoli org>
- To: evolution-patches ximian com
- Subject: Patch for memory read problem [#43119]
- Date: 17 May 2003 16:00:24 -0400
Sigh, ETableState needs a real API...
-- Ettore
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/shell/ChangeLog,v
retrieving revision 1.1275
diff -u -p -r1.1275 ChangeLog
--- ChangeLog 15 May 2003 18:19:16 -0000 1.1275
+++ ChangeLog 17 May 2003 19:39:50 -0000
@@ -1,3 +1,9 @@
+2003-05-17 Ettore Perazzoli <ettore ximian com>
+
+ * e-storage-set-view.c (e_storage_set_view_set_show_checkboxes):
+ Reallocate the "expansions" member of ETreeState as well, to avoid
+ a memory error. [#43119]
+
2003-05-15 Ettore Perazzoli <ettore ximian com>
* e-shell.c (parse_default_uri): Protect against the component
Index: e-storage-set-view.c
===================================================================
RCS file: /cvs/gnome/evolution/shell/e-storage-set-view.c,v
retrieving revision 1.187
diff -u -p -r1.187 e-storage-set-view.c
--- e-storage-set-view.c 4 Mar 2003 20:39:02 -0000 1.187
+++ e-storage-set-view.c 17 May 2003 19:39:52 -0000
@@ -2316,12 +2316,17 @@ e_storage_set_view_set_show_checkboxes (
priv->show_checkboxes = show;
state = e_tree_get_state_object (E_TREE (storage_set_view));
- g_free (state->columns);
state->col_count = show ? 2 : 1;
- state->columns = g_new(int, state->col_count);
+ state->columns = g_renew (int, state->columns, state->col_count);
state->columns [state->col_count - 1] = 0;
if (show)
state->columns [0] = 1;
+
+ state->expansions = g_renew (double, state->expansions, state->col_count);
+ state->expansions [0] = 1.0;
+ if (show)
+ state->expansions [1] = 1.0;
+
e_tree_set_state_object (E_TREE (storage_set_view), state);
priv->has_checkbox_func = has_checkbox_func;
--- End Message ---
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]