IBR-DTNSuite  0.8
tools/src/dtntunnel.cpp File Reference
#include "config.h"
#include <iostream>
#include <stdlib.h>
#include "ibrdtn/api/Client.h"
#include "ibrdtn/api/Bundle.h"
#include "ibrdtn/api/BLOBBundle.h"
#include "ibrdtn/api/StringBundle.h"
#include "ibrcommon/net/tcpclient.h"
#include "ibrcommon/thread/Mutex.h"
#include "ibrcommon/thread/MutexLock.h"
#include <queue>
#include <csignal>
#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <linux/if.h>
Include dependency graph for dtntunnel.cpp:

Go to the source code of this file.

Defines

#define tun_open_common(dev, type)   tun_open_common0(dev, type)

Functions

int tun_open (char *dev)
int tap_open (char *dev)
void term (int signal)
int main (int argc, char *argv[])

Variables

bool m_running = true
int tunnel_fd = -1

Define Documentation

#define tun_open_common (   dev,
  type 
)    tun_open_common0(dev, type)

Definition at line 129 of file dtntunnel.cpp.

Referenced by tap_open(), and tun_open().


Function Documentation

int main ( int  argc,
char *  argv[] 
)

Definition at line 193 of file dtntunnel.cpp.

References ibrcommon::BLOB::create(), ibrcommon::BLOB::Reference::iostream(), m_running, term(), tun_open(), and tunnel_fd.

Here is the call graph for this function:

int tap_open ( char *  dev)

Definition at line 134 of file dtntunnel.cpp.

References tun_open_common.

void term ( int  signal)

Definition at line 183 of file dtntunnel.cpp.

References m_running, and tunnel_fd.

int tun_open ( char *  dev)

Definition at line 133 of file dtntunnel.cpp.

References tun_open_common.

Referenced by main().


Variable Documentation

bool m_running = true

Definition at line 180 of file dtntunnel.cpp.

Referenced by main(), and term().

int tunnel_fd = -1

Definition at line 181 of file dtntunnel.cpp.

Referenced by main(), and term().