[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: RE: RE: StdProp overhaul, take 2



Le mer, aoû 15, 2001, à 05:41:08 +0930, Young, Robert a écrit:

> The patch worked OK (I'm a bit new to this patch thing, but that's what man
> is for :-) but there's now another problem (with the new patched dia),
> possibly related:
> Create new diagram, place a custom shape (e.g. resistor from Circuit sheet),
> select modify tool. Copy. Dia segfaults, and gdb gives:
> 
> Program terminated with signal 11, Segmentation fault.
> #0  text_get_attributes (text=0x0, attr=0x81cd854) at text.c:939
> 939	  attr->font = text->font;
> 
> This doesn't happen if the object has text associated with it, e.g. Computer
> from the Network sheet.

> Hope this helps.

This does. Fixed now. Thanks ! 

	-- Cyrille


-- 
Grumpf.

? lib/text.c.heldoff.patch
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/dia/ChangeLog,v
retrieving revision 1.678
diff -u -r1.678 ChangeLog
--- ChangeLog	2001/08/15 07:07:24	1.678
+++ ChangeLog	2001/08/15 10:09:59
@@ -1,5 +1,10 @@
 2001-08-15  Cyrille Chepelov <chepelov@calixo.net>
 
+	* objects/custom/custom_object.c: (custom_copy): don't call
+	text_get_attrbutes if the shape has no text...
+
+2001-08-15  Cyrille Chepelov <chepelov@calixo.net>
+
 	* lib/properties.h: added comments next to the PROP_TYPEs to tell
 	which C Property subclass to use.
 	
Index: objects/custom/custom_object.c
===================================================================
RCS file: /cvs/gnome/dia/objects/custom/custom_object.c,v
retrieving revision 1.42
diff -u -r1.42 custom_object.c
--- objects/custom/custom_object.c	2001/08/13 07:24:43	1.42
+++ objects/custom/custom_object.c	2001/08/15 10:10:00
@@ -1284,10 +1284,10 @@
   newcustom->flip_h = custom->flip_h;
   newcustom->flip_v = custom->flip_v;
 
-  if (custom->info->has_text)
+  if (custom->info->has_text) {
     newcustom->text = text_copy(custom->text);
-  text_get_attributes(newcustom->text,&newcustom->attrs);
-
+    text_get_attributes(newcustom->text,&newcustom->attrs);
+  } 
   newcustom->connections = g_new0(ConnectionPoint, custom->info->nconnections);
 
   for (i = 0; i < custom->info->nconnections; i++) {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] Mail converted by Mofo Magic and the Flying D

 
All trademarks and copyrights are the property of their respective owners.

Other Directory Sites: SeekWonder | Directory Owners Forum

GuideSMACK