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

gEDA-cvs: branch: master updated (1.1.2.20070818-32-g615d039)



The branch, master has been updated
       via  615d03958528afabaf94eb95199aa434d5c5d667 (commit)
      from  7f8f105c3fb9945ee02a4cf35a3cd762b0c6804c (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
=========

 libgeda/src/s_basic.c |   26 +++-----------------------
 1 files changed, 3 insertions(+), 23 deletions(-)


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

commit 615d03958528afabaf94eb95199aa434d5c5d667
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Wed Sep 5 14:34:11 2007 +0100

    Use o_attrib_print() in libgeda/src/s_basic.c avoiding code duplication.
    
    Printed output will be slightly different, but this is just debug code.

:100644 100644 7f4c35c... ba0f74b... M	libgeda/src/s_basic.c

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

commit 615d03958528afabaf94eb95199aa434d5c5d667
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Wed Sep 5 14:34:11 2007 +0100

    Use o_attrib_print() in libgeda/src/s_basic.c avoiding code duplication.
    
    Printed output will be slightly different, but this is just debug code.

diff --git a/libgeda/src/s_basic.c b/libgeda/src/s_basic.c
index 7f4c35c..ba0f74b 100644
--- a/libgeda/src/s_basic.c
+++ b/libgeda/src/s_basic.c
@@ -259,8 +259,6 @@ OBJECT *s_basic_link_object( OBJECT *new_node, OBJECT *ptr )
 void print_struct_forw(OBJECT *ptr)
 {
   OBJECT *o_current=NULL;
-  ATTRIB *attr=NULL;
-  int i;
 
   o_current = ptr;
 
@@ -278,16 +276,7 @@ void print_struct_forw(OBJECT *ptr)
       print_struct_forw(o_current->complex->prim_objs);
     }
 
-	
-    if (o_current->attribs) {
-      attr = o_current->attribs;
-      i = 0;
-      while (attr != NULL) {
-        if (attr->object != NULL) 
-          printf("%d attribute %s\n", i, attr->object->name);
-        attr = attr->next;
-      }    
-    }
+    o_attrib_print (o_current->attribs);
 
     printf("----\n");
     o_current = o_current->next;
@@ -322,8 +311,6 @@ void print_struct_back(OBJECT *ptr)
 void print_struct(OBJECT *ptr)
 {
   OBJECT *o_current=NULL;
-  ATTRIB *attr=NULL;
-  int i;
 
   o_current = ptr;
 
@@ -338,15 +325,8 @@ void print_struct(OBJECT *ptr)
       printf("Line points.y2: %d\n", o_current->line->y[1]);
     }
 
-    if (o_current->attribs) {
-      attr = o_current->attribs;
-      i = 0;
-      while (attr != NULL) {
-        printf("%d attribute %s\n", i, attr->object->name);
-        attr = attr->next;
-      }
-		
-    }
+    o_attrib_print (o_current->attribs);
+
     printf("----\n");
   }
 }




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