// check for tunnel state and define tunnel_up (xrs,t3ss)
t = GCP_get_tunnel (cc->destination, GNUNET_YES);
- create_msg->tunnel_up = GCT_get_estate(t) == CADET_TUNNEL_KEY_UNINITIALIZED ? GNUNET_NO : GNUNET_YES;
+ if (NULL != t)
+ {
+ create_msg->tunnel_up = (GCT_get_estate(t) == CADET_TUNNEL_KEY_UNINITIALIZED) &&
+ (GCT_alice_or_betty (GCP_get_id(cc->destination)) == GNUNET_NO)
+ ? GNUNET_NO : GNUNET_YES;
+ }
pids = (struct GNUNET_PeerIdentity *) &create_msg[1];
pids[0] = my_full_id;
cc = GNUNET_new (struct CadetConnection);
cc->state = init_state;
cc->ct = ct;
+ cc->destination = destination; /* xrs,t3ss,lurchi*/
cc->cid = *cid;
cc->retry_delay =
GNUNET_TIME_relative_multiply (INITIAL_CONNECTION_CREATE_RETRY_DELAY, off);