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

gEDA-cvs: gaf.git: branch: master updated (1.6.1-20100214-83-g5cad2cd)



The branch, master has been updated
       via  5cad2cd9a184e1af8273dba6d8ddc3c02a2b72d6 (commit)
      from  8e3d9a6a219ee166260bdc1e1d2980878b524450 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 gschem/src/o_grips.c |   65 ++++++++++++++++++-------------------------------
 1 files changed, 24 insertions(+), 41 deletions(-)


=================
 Commit Messages
=================

commit 5cad2cd9a184e1af8273dba6d8ddc3c02a2b72d6
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Commit: Peter Clifton <pcjc2@xxxxxxxxx>

    gschem: Tidy up o_grips_end_{net,pin,bus}() a little
    
    Somewhat of a pointless change, but I ended up moving these functions
    about a bit in another patch - so I figured a NOP patch to do most of
    the tidying would be better than mixing this with functional changes.

:100644 100644 db80232... e99a75d... M	gschem/src/o_grips.c

=========
 Changes
=========

commit 5cad2cd9a184e1af8273dba6d8ddc3c02a2b72d6
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Commit: Peter Clifton <pcjc2@xxxxxxxxx>

    gschem: Tidy up o_grips_end_{net,pin,bus}() a little
    
    Somewhat of a pointless change, but I ended up moving these functions
    about a bit in another patch - so I figured a NOP patch to do most of
    the tidying would be better than mixing this with functional changes.

diff --git a/gschem/src/o_grips.c b/gschem/src/o_grips.c
index db80232..e99a75d 100644
--- a/gschem/src/o_grips.c
+++ b/gschem/src/o_grips.c
@@ -1366,8 +1366,8 @@ void o_grips_end_line(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichon
 void o_grips_end_net(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone)
 {
   TOPLEVEL *toplevel = w_current->toplevel;
-  GList *prev_conn_objects = NULL;
-  GList *connected_objects = NULL;
+  GList *prev_conn_objects;
+  GList *connected_objects;
 
   /* erase the temporary line */
   /* o_line_invalidate_rubber (w_current); */
@@ -1384,7 +1384,7 @@ void o_grips_end_net(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
   /* remove the old net */
   o_invalidate (w_current, o_current);
 
-  prev_conn_objects = s_conn_return_others (prev_conn_objects, o_current);
+  prev_conn_objects = s_conn_return_others (NULL, o_current);
 
   s_conn_remove_object (toplevel, o_current);
   o_net_modify (toplevel, o_current, w_current->second_wx,
@@ -1392,29 +1392,21 @@ void o_grips_end_net(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
   s_conn_update_object (toplevel, o_current);
 
   /* get the other connected objects and redraw them */
-  connected_objects = s_conn_return_others(connected_objects,
-					   o_current);
+  connected_objects = s_conn_return_others (NULL, o_current);
   /* add bus rippers if necessary */
-  o_net_add_busrippers(w_current, o_current, connected_objects);
+  o_net_add_busrippers (w_current, o_current, connected_objects);
+  g_list_free (connected_objects);
 
   /* draw the object objects */
   o_invalidate_glist (w_current, prev_conn_objects);
-  
+  g_list_free (prev_conn_objects);
+
   o_invalidate (w_current, o_current);
-  
-  g_list_free(connected_objects);
-  connected_objects = NULL;
-  
+
   /* get the other connected objects and redraw them */
-  connected_objects = s_conn_return_others(connected_objects,
-					   o_current);
-  
+  connected_objects = s_conn_return_others (NULL, o_current);
   o_invalidate_glist (w_current, connected_objects);
-
-  g_list_free (prev_conn_objects);
-  prev_conn_objects = NULL;
-  g_list_free(connected_objects);
-  connected_objects = NULL;
+  g_list_free (connected_objects);
 }
 
 /*! \brief End process of modifying pin object with grip.
@@ -1436,8 +1428,8 @@ void o_grips_end_net(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
 void o_grips_end_pin(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone)
 {
   TOPLEVEL *toplevel = w_current->toplevel;
-  GList *prev_conn_objects = NULL;
-  GList *connected_objects = NULL;
+  GList *prev_conn_objects;
+  GList *connected_objects;
 
   /* erase the temporary line */
   /* o_line_invalidate_rubber (w_current); */
@@ -1454,7 +1446,7 @@ void o_grips_end_pin(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
   /* erase old pin object */
   o_invalidate (w_current, o_current);
 
-  prev_conn_objects = s_conn_return_others (prev_conn_objects, o_current);
+  prev_conn_objects = s_conn_return_others (NULL, o_current);
 
   s_conn_remove_object (toplevel, o_current);
   o_pin_modify (toplevel, o_current, w_current->second_wx,
@@ -1464,17 +1456,13 @@ void o_grips_end_pin(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
 
   /* redraw the object connections */
   o_invalidate_glist (w_current, prev_conn_objects);
+  g_list_free (prev_conn_objects);
 
   /* get the other connected objects and redraw them */
-  connected_objects = s_conn_return_others(connected_objects,
-					   o_current);
+  connected_objects = s_conn_return_others (NULL, o_current);
   o_invalidate_glist (w_current, connected_objects);
+  g_list_free (connected_objects);
 
-  /* free the two lists */
-  g_list_free (prev_conn_objects);
-  prev_conn_objects = NULL;
-  g_list_free(connected_objects);
-  connected_objects = NULL;
 }
 
 /*! \brief End process of modifying bus object with grip.
@@ -1496,8 +1484,8 @@ void o_grips_end_pin(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
 void o_grips_end_bus(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone)
 {
   TOPLEVEL *toplevel = w_current->toplevel;
-  GList *prev_conn_objects = NULL;
-  GList *connected_objects = NULL;
+  GList *prev_conn_objects;
+  GList *connected_objects;
 
   /* erase the temporary line */
   /* o_line_invalidate_rubber (w_current); */
@@ -1514,9 +1502,9 @@ void o_grips_end_bus(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
   /* erase the old bus and it's cues */
   o_invalidate (w_current, o_current);
 
-  prev_conn_objects = s_conn_return_others (prev_conn_objects, o_current);
-  s_conn_remove_object (toplevel, o_current);
+  prev_conn_objects = s_conn_return_others (NULL, o_current);
 
+  s_conn_remove_object (toplevel, o_current);
   o_bus_modify (toplevel, o_current, w_current->second_wx,
                 w_current->second_wy, w_current->which_grip);
   s_conn_update_object (toplevel, o_current);
@@ -1524,17 +1512,12 @@ void o_grips_end_bus(GSCHEM_TOPLEVEL *w_current, OBJECT *o_current, int whichone
 
   /* redraw the connected objects */
   o_invalidate_glist (w_current, prev_conn_objects);
+  g_list_free (prev_conn_objects);
 
   /* get the other connected objects and redraw them */
-  connected_objects = s_conn_return_others(connected_objects,
-					   o_current);
+  connected_objects = s_conn_return_others (NULL, o_current);
   o_invalidate_glist (w_current, connected_objects);
-
-  /* free the two lists */
-  g_list_free (prev_conn_objects);
-  prev_conn_objects = NULL;
-  g_list_free(connected_objects);
-  connected_objects = NULL;
+  g_list_free (connected_objects);
 }
 
 




_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs