File: udp.h

package info (click to toggle)
conquest 8.1-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 7,984 kB
  • ctags: 3,086
  • sloc: ansic: 39,393; sh: 8,540; yacc: 446; makefile: 296; lex: 146
file content (27 lines) | stat: -rw-r--r-- 826 bytes parent folder | download | duplicates (3)
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
27
/* borrowed from bzflag
 * Copyright (c) 1993 - 2003 Tim Riker
 *
 * I hacked it up somewhat - for straight C, and to better fit in with Conquest.
 * JET
 *
 * This package is free software;  you can redistribute it and/or
 * modify it under the terms of the LGPL. [JET]
 *
 * THIS PACKAGE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 */

#ifndef	_UDP_H
#define	_UDP_H

#include <sys/types.h>

int udpOpen(int port, struct sockaddr_in* addr);
int udpClose(int fd);
int udpSend(int fd, const void* buffer,
                   int bufferLength, const struct sockaddr_in*);
int udpRecv(int fd, void* buffer,
                   int bufferLength, struct sockaddr_in*);

#endif /* _UDP_H */