comparison libnnchat.h @ 71:3a23c2adfb78

Remove tabs from indentation.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 14 Nov 2008 08:49:40 +0200
parents 3ab7751fdad1
children 745f670068dc
comparison
equal deleted inserted replaced
70:5228ad7b4f57 71:3a23c2adfb78
20 20
21 #include <errno.h> 21 #include <errno.h>
22 #include "th_string.h" 22 #include "th_string.h"
23 23
24 #define SET_BUFSIZE (4096) 24 #define SET_BUFSIZE (4096)
25 #define SET_ALLOC_SIZE (128) 25 #define SET_ALLOC_SIZE (128)
26 26
27 typedef struct { 27 typedef struct {
28 char **data; 28 char **data;
29 size_t n, size; 29 size_t n, size;
30 } ringbuf_t; 30 } ringbuf_t;
31 31
32 typedef struct { 32 typedef struct {
33 ssize_t pos, len, size; 33 ssize_t pos, len, size;
34 char *data; 34 char *data;
35 } editbuf_t; 35 } editbuf_t;
36 36
37 37
38 int openConnection(struct in_addr *addr, const int port); 38 int openConnection(struct in_addr *addr, const int port);
39 void closeConnection(const int sock); 39 void closeConnection(const int sock);
40 BOOL sendToSocket(const int sock, char *buf, const size_t bufLen); 40 BOOL sendToSocket(const int sock, char *buf, const size_t bufLen);
41 BOOL sendUserMsg(const int sock, const char *user, const char *fmt, ...); 41 BOOL sendUserMsg(const int sock, const char *user, const char *fmt, ...);
42 42
43 43
44 char * encodeStr1(const char *str); 44 char * encodeStr1(const char *str);
45 char * decodeStr1(const char *str); 45 char * decodeStr1(const char *str);
46 char * encodeStr2(const char *str); 46 char * encodeStr2(const char *str);
47 char * decodeStr2(const char *str); 47 char * decodeStr2(const char *str);
48 char * stripXMLTags(const char *str); 48 char * stripXMLTags(const char *str);
49 49
50 50
51 ringbuf_t * newRingBuf(const size_t size); 51 ringbuf_t * newRingBuf(const size_t size);
52 void freeRingBuf(ringbuf_t *buf); 52 void freeRingBuf(ringbuf_t *buf);
53 void addRingBuf(ringbuf_t *buf, const char *str); 53 void addRingBuf(ringbuf_t *buf, const char *str);