summaryrefslogtreecommitdiff
path: root/src/thrd/thrd.cpp
blob: 63135a82f955bf6495696a0b6915099d0494b6a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#ifndef THRD_CPP
#define THRD_CPP

#include "thrd.h"
#include <sys/socket.h>

using namespace std;

thrd::thrd( int i_sock )
{
    this->i_sock = i_sock;
}

thrd::~thrd()
{
    shutdown ( get_sock() , 2 );
    close    ( get_sock()     );
}

void
thrd::run()
{
    wrap::SOCK->read_write( this, i_sock );
}

#endif