Revision 3fe5f899

View differences:

proto/rip/rip.c
572 572
  assert( sizeof(struct rip_block) == 20);
573 573
  assert( sizeof(struct rip_block_auth) == 20);
574 574

  
575

  
575
#ifdef LOCAL_DEBUG
576 576
  P->magic = RIP_MAGIC;
577
#endif
577 578
  fib_init( &P->rtable, p->pool, sizeof( struct rip_entry ), 0, NULL );
578 579
  init_list( &P->connections );
579 580
  init_list( &P->garbage );
proto/rip/rip.h
146 146
  struct fib rtable;
147 147
  list garbage;
148 148
  list interfaces;	/* Interfaces we really know about */
149
#ifdef LOCAL_DEBUG
149 150
  int magic;
151
#endif
150 152
  int tx_count;		/* Do one regular update once in a while */
151 153
};
152 154

  
153

  
155
#ifdef LOCAL_DEBUG
154 156
#define RIP_MAGIC 81861253
155 157
#define CHK_MAGIC do { if (P->magic != RIP_MAGIC) bug( "Not enough magic" ); } while (0)
158
#else
159
#define CHK_MAGIC do { } while (0)
160
#endif
161

  
156 162

  
157 163
void rip_init_instance(struct proto *p);
158 164
void rip_init_config(struct rip_proto_config *c);

Also available in: Unified diff