File: tcp.h

package info (click to toggle)
postit 0.5-1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 160 kB
  • ctags: 218
  • sloc: ansic: 753; sh: 243; makefile: 61
file content (12 lines) | stat: -rw-r--r-- 456 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
#ifndef __TCP_H__
#define __TCP_H__

int tcp_open_connection(char *hostname, unsigned short port);
int tcp_close_connection(int socknr);
int tcp_receive_line(int socknr, char *line, int maxsize);
int tcp_receive_line_to(int socknr, char *line, int maxsize, long timeout);
int tcp_receive_block_to(int socknr, char *block, int maxsize, long timeout);
int tcp_send_line(int socknr, char *line);
int tcp_send_block(int socknr, char *block, int size);

#endif