-/**
- * Initiate peer p1 to connect to peer p2
- * Get peer p2's HELLO and offer it to p1
- * p1 then tries to connect to p2
- * @param p1 peer 1
- * @param p2 peer 2
- * @param cb the callback to call
- * @param cb_cls callback cls
- * @return connect context
- */
-GNUNET_TRANSPORT_TESTING_ConnectRequest
-GNUNET_TRANSPORT_TESTING_connect_peers (struct TransportTestingHandle * tth,
- struct PeerContext *p1,
- struct PeerContext *p2,
- GNUNET_TRANSPORT_TESTING_connect_cb cb,
- void *cb_cls)
-
-{
- struct ConnectingContext *cc =
- GNUNET_malloc (sizeof (struct ConnectingContext));
-
- GNUNET_assert (p1 != NULL);
- GNUNET_assert (p2 != NULL);
-
- cc->p1 = p1;
- cc->p2 = p2;
-
- cc->cb = cb;
- cc->cb_cls = cb_cls;
-
- cc->th_p1 = p1->th;
- /* GNUNET_TRANSPORT_connect (cc->p1->cfg, NULL, cc, NULL,
- ¬ify_connect_internal, NULL);*/
-
- cc->th_p2 = p2->th;
- /* GNUNET_TRANSPORT_connect (cc->p2->cfg, NULL, cc, NULL,
- ¬ify_connect_internal, NULL);*/
-
- GNUNET_assert (cc->th_p1 != NULL);
- GNUNET_assert (cc->th_p2 != NULL);
-
- GNUNET_CONTAINER_DLL_insert (tth->cc_head, tth->cc_tail, cc);
-
- cc->tct = GNUNET_SCHEDULER_add_now (&try_connect, cc);
- return cc;
-
-
-}