ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/gvpe/src/vpn_dns.C
(Generate patch)

Comparing gvpe/src/vpn_dns.C (file contents):
Revision 1.43 by pcg, Sat Dec 1 23:35:31 2007 UTC vs.
Revision 1.46 by pcg, Thu Dec 6 00:35:29 2007 UTC

42#include <unistd.h> 42#include <unistd.h>
43#include <fcntl.h> 43#include <fcntl.h>
44 44
45#include <map> 45#include <map>
46 46
47#include <cstdio> /* bug in libgmp: gmp.h relies on cstdio being included */
47#include <gmp.h> 48#include <gmp.h>
48 49
49#include "netcompat.h" 50#include "netcompat.h"
50 51
51#include "vpn.h" 52#include "vpn.h"
559 vector<dns_rcv *> rcvpq; 560 vector<dns_rcv *> rcvpq;
560 561
561 byte_stream rcvdq; int rcvseq; int repseq; 562 byte_stream rcvdq; int rcvseq; int repseq;
562 byte_stream snddq; int sndseq; 563 byte_stream snddq; int sndseq;
563 564
564 void time_cb (ev::timer &w, int revents); ev::timer tw; 565 inline void time_cb (ev::timer &w, int revents); ev::timer tw;
565 void receive_rep (dns_rcv *r); 566 void receive_rep (dns_rcv *r);
566 567
567 dns_connection (connection *c); 568 dns_connection (connection *c);
568 ~dns_connection (); 569 ~dns_connection ();
569}; 570};
724 725
725dns_connection::dns_connection (connection *c) 726dns_connection::dns_connection (connection *c)
726: c (c) 727: c (c)
727, rcvdq (MAX_BACKLOG * 2) 728, rcvdq (MAX_BACKLOG * 2)
728, snddq (MAX_BACKLOG) 729, snddq (MAX_BACKLOG)
729, tw (this, &dns_connection::time_cb)
730{ 730{
731 tw.set<dns_connection, &dns_connection::time_cb> (this);
732
731 vpn = c->vpn; 733 vpn = c->vpn;
732 734
733 established = false; 735 established = false;
734 736
735 rcvseq = repseq = sndseq = 0; 737 rcvseq = repseq = sndseq = 0;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines