Revision 579e2c14
chunker_streamer/chunk_pusher.c | ||
---|---|---|
27 | 27 |
static bool tcp_fd_connected = false; |
28 | 28 |
static char* peer_ip; |
29 | 29 |
static int peer_port; |
30 |
static bool exit_on_connect_failure = false; |
|
30 | 31 |
static bool connect_on_data = true; |
31 | 32 |
|
32 | 33 |
void initTCPPush(char* ip, int port) |
... | ... | |
47 | 48 |
int result = connect(tcp_fd, (struct sockaddr *)&address, sizeof(struct sockaddr_in)); |
48 | 49 |
if(result == -1){ |
49 | 50 |
fprintf(stderr, "TCP OUTPUT MODULE: could not connect to the peer!\n"); |
51 |
if (exit_on_connect_failure) { |
|
52 |
exit(1); |
|
53 |
} |
|
50 | 54 |
tcp_fd_connected = false; |
51 | 55 |
} else { |
52 | 56 |
tcp_fd_connected = true; |
Also available in: Unified diff