summaryrefslogtreecommitdiffstats
path: root/utils.h
diff options
context:
space:
mode:
Diffstat (limited to 'utils.h')
-rw-r--r--utils.h16
1 files changed, 7 insertions, 9 deletions
diff --git a/utils.h b/utils.h
index 465487d..9a6d566 100644
--- a/utils.h
+++ b/utils.h
@@ -18,8 +18,8 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 18
19*/ 19*/
20 20
21#ifndef __LOG_H__ 21#ifndef __UTILS_H__
22#define __LOG_H__ 22#define __UTILS_H__
23 23
24#include <poll.h> 24#include <poll.h>
25 25
@@ -29,19 +29,17 @@ enum fdowner {
29 FD_USB 29 FD_USB
30}; 30};
31 31
32typedef struct { 32struct fdlist {
33 int count; 33 int count;
34 int capacity; 34 int capacity;
35 enum fdowner *owners; 35 enum fdowner *owners;
36 struct pollfd *fds; 36 struct pollfd *fds;
37} fdlist; 37};
38 38
39void fdlist_create(fdlist *list); 39void fdlist_create(struct fdlist *list);
40void fdlist_add(fdlist *list, enum fdowner owner, int fd, short events); 40void fdlist_add(struct fdlist *list, enum fdowner owner, int fd, short events);
41void fdlist_free(fdlist *list); 41void fdlist_free(struct fdlist *list);
42 42
43#define MIN(X, Y) ((X) < (Y) ? (X) : (Y)) 43#define MIN(X, Y) ((X) < (Y) ? (X) : (Y))
44 44
45
46
47#endif 45#endif