Index: trunk/src/global_typedefs.h =================================================================== --- trunk/src/global_typedefs.h (revision 23137) +++ trunk/src/global_typedefs.h (revision 23138) @@ -37,6 +37,7 @@ typedef struct pcb_polyarea_s pcb_polyarea_t; typedef struct pcb_buffer_s pcb_buffer_t; typedef struct pcb_net_s pcb_net_t; +typedef struct pcb_oldnet_s pcb_oldnet_t; typedef struct pcb_connection_s pcb_connection_t; typedef struct pcb_box_s pcb_box_t; typedef struct pcb_box_list_s pcb_box_list_t; Index: trunk/src/netlist.c =================================================================== --- trunk/src/netlist.c (revision 23137) +++ trunk/src/netlist.c (revision 23138) @@ -272,16 +272,16 @@ /* --------------------------------------------------------------------------- * get next slot for a subnet, allocates memory if necessary */ -pcb_net_t *pcb_net_new(pcb_board_t *pcb, pcb_netlist_t *Netlist) +pcb_oldnet_t *pcb_net_new(pcb_board_t *pcb, pcb_netlist_t *Netlist) { - pcb_net_t *net = Netlist->Net; + pcb_oldnet_t *net = Netlist->Net; /* realloc new memory if necessary and clear it */ if (Netlist->NetN >= Netlist->NetMax) { Netlist->NetMax += STEP_POINT; - net = (pcb_net_t *) realloc(net, Netlist->NetMax * sizeof(pcb_net_t)); + net = (pcb_oldnet_t *) realloc(net, Netlist->NetMax * sizeof(pcb_oldnet_t)); Netlist->Net = net; - memset(net + Netlist->NetN, 0, STEP_POINT * sizeof(pcb_net_t)); + memset(net + Netlist->NetN, 0, STEP_POINT * sizeof(pcb_oldnet_t)); } net->type = PCB_OBJ_NET; @@ -342,11 +342,11 @@ /* --------------------------------------------------------------------------- * frees memory used by a subnet */ -void pcb_net_free(pcb_net_t *Net) +void pcb_net_free(pcb_oldnet_t *Net) { if (Net) { free(Net->Connection); - memset(Net, 0, sizeof(pcb_net_t)); + memset(Net, 0, sizeof(pcb_oldnet_t)); } } Index: trunk/src/netlist.h =================================================================== --- trunk/src/netlist.h (revision 23137) +++ trunk/src/netlist.h (revision 23138) @@ -35,7 +35,7 @@ #include "route_style.h" #include "obj_common.h" -struct pcb_net_s { /* holds a net of connections */ +struct pcb_oldnet_s { /* holds a net of connections */ PCB_ANY_OBJ_FIELDS; pcb_cardinal_t ConnectionN, /* the number of connections contained */ ConnectionMax; /* max connections from malloc */ @@ -46,7 +46,7 @@ typedef struct { /* holds a list of nets */ pcb_cardinal_t NetN, /* the number of subnets contained */ NetMax; /* max subnets from malloc */ - pcb_net_t *Net; + pcb_oldnet_t *Net; } pcb_netlist_t; typedef struct { /* holds a list of net lists */ @@ -97,11 +97,11 @@ #define PCB_NETLIST_INVALID_INDEX ((pcb_cardinal_t)(-1)) -pcb_net_t *pcb_net_new(pcb_board_t *pcb, pcb_netlist_t *); +pcb_oldnet_t *pcb_net_new(pcb_board_t *pcb, pcb_netlist_t *); pcb_netlist_t *pcb_netlist_new(pcb_netlist_list_t *); void pcb_netlist_list_free(pcb_netlist_list_t *); void pcb_netlist_free(pcb_netlist_t *); -void pcb_net_free(pcb_net_t *); +void pcb_net_free(pcb_oldnet_t *); #define PCB_NETLIST_LOOP(top) do { \ pcb_cardinal_t n; \ @@ -112,7 +112,7 @@ #define PCB_NET_LOOP(top) do { \ pcb_cardinal_t n; \ - pcb_net_t * net; \ + pcb_oldnet_t * net; \ for (n = (top)->NetN-1; n != -1; n--) \ { \ net = &(top)->Net[n] Index: trunk/src/rats.c =================================================================== --- trunk/src/rats.c (revision 23137) +++ trunk/src/rats.c (revision 23138) @@ -66,7 +66,7 @@ static pcb_bool DrawShortestRats(pcb_netlist_t *, void (*)(register pcb_connection_t *, register pcb_connection_t *, register pcb_route_style_t *)); static pcb_bool CheckShorts(pcb_lib_menu_t *); -static void TransferNet(pcb_netlist_t *, pcb_net_t *, pcb_net_t *); +static void TransferNet(pcb_netlist_t *, pcb_oldnet_t *, pcb_oldnet_t *); static pcb_bool badnet = pcb_false; static pcb_layergrp_id_t Sgrp = -1, Cgrp = -1; /* layer group holding solder/component side */ @@ -216,7 +216,7 @@ { pcb_connection_t *connection; pcb_connection_t LastPoint; - pcb_net_t *net; + pcb_oldnet_t *net; static pcb_netlist_t *Wantlist = NULL; if (!net_menu->MenuN) @@ -289,7 +289,7 @@ } /* copy all connections from one net into another and then remove the first net from its netlist */ -static void TransferNet(pcb_netlist_t *Netl, pcb_net_t *SourceNet, pcb_net_t *DestNet) +static void TransferNet(pcb_netlist_t *Netl, pcb_oldnet_t *SourceNet, pcb_oldnet_t *DestNet) { pcb_connection_t *conn; @@ -306,7 +306,7 @@ /* remove SourceNet from its netlist */ *SourceNet = Netl->Net[--(Netl->NetN)]; /* zero out old garbage */ - memset(&Netl->Net[Netl->NetN], 0, sizeof(pcb_net_t)); + memset(&Netl->Net[Netl->NetN], 0, sizeof(pcb_oldnet_t)); } static void **found_short(pcb_any_obj_t *parent, pcb_any_obj_t *term, vtp0_t *generic, pcb_lib_menu_t *theNet, void **menu) @@ -431,7 +431,7 @@ return warn; } -static void gather_subnet_objs(pcb_data_t *data, pcb_netlist_t *Netl, pcb_net_t *a) +static void gather_subnet_objs(pcb_data_t *data, pcb_netlist_t *Netl, pcb_oldnet_t *a) { pcb_connection_t *conn; @@ -508,7 +508,7 @@ * afterwards there can be many fewer nets with multiple connections each */ static pcb_bool gather_subnets(pcb_netlist_t *Netl, pcb_bool NoWarn, pcb_bool AndRats) { - pcb_net_t *a, *b; + pcb_oldnet_t *a, *b; pcb_bool Warned = pcb_false; pcb_cardinal_t m, n; @@ -560,7 +560,7 @@ pcb_bool changed = pcb_false; pcb_bool havepoints; pcb_cardinal_t n, m, j; - pcb_net_t *next, *subnet, *theSubnet = NULL; + pcb_oldnet_t *next, *subnet, *theSubnet = NULL; /* This is just a sanity check, to make sure we're passed * *something*. @@ -697,7 +697,7 @@ void (*funcp) (register pcb_connection_t *, register pcb_connection_t *, register pcb_route_style_t *)) { pcb_netlist_t *Nets, *Wantlist; - pcb_net_t *lonesome; + pcb_oldnet_t *lonesome; pcb_connection_t *onepin; pcb_bool changed, Warned = pcb_false; @@ -780,7 +780,7 @@ { pcb_netlist_list_t result = { 0, 0, NULL }; pcb_netlist_t *Nets, *Wantlist; - pcb_net_t *lonesome; + pcb_oldnet_t *lonesome; pcb_connection_t *onepin; /* the netlist library has the text form @@ -963,7 +963,7 @@ } /* get next slot for a connection, allocates memory if necessary */ -pcb_connection_t *pcb_rat_connection_alloc(pcb_net_t *Net) +pcb_connection_t *pcb_rat_connection_alloc(pcb_oldnet_t *Net) { pcb_connection_t *con = Net->Connection; Index: trunk/src/rats.h =================================================================== --- trunk/src/rats.h (revision 23137) +++ trunk/src/rats.h (revision 23138) @@ -63,7 +63,7 @@ pcb_netlist_list_t pcb_rat_collect_subnets(pcb_bool SelectedOnly); -pcb_connection_t *pcb_rat_connection_alloc(pcb_net_t *Net); +pcb_connection_t *pcb_rat_connection_alloc(pcb_oldnet_t *Net); #define PCB_CONNECTION_LOOP(net) do { \ long n; \ Index: trunk/src_plugins/autoplace/autoplace.c =================================================================== --- trunk/src_plugins/autoplace/autoplace.c (revision 23137) +++ trunk/src_plugins/autoplace/autoplace.c (revision 23138) @@ -355,7 +355,7 @@ * all-SMD nets by making the rectangle a cube and weighting * the "layer height" of the net. */ for (i = 0; i < Nets->NetN; i++) { - pcb_net_t *n = &Nets->Net[i]; + pcb_oldnet_t *n = &Nets->Net[i]; if (n->ConnectionN < 2) continue; /* no cost to go nowhere */ minx = maxx = n->Connection[0].X;