summaryrefslogtreecommitdiff
path: root/crawler.c
diff options
context:
space:
mode:
Diffstat (limited to 'crawler.c')
-rw-r--r--crawler.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crawler.c b/crawler.c
index a1a5ead..e30d09b 100644
--- a/crawler.c
+++ b/crawler.c
@@ -293,7 +293,7 @@ static int lru_crawler_poll(crawler_client_t *c) {
if (to_poll[0].revents & POLLIN) {
char buf[1];
- int res = read(c->sfd, buf, 1);
+ int res = ((conn*)c->c)->read(c->c, buf, 1);
if (res == 0 || (res == -1 && (errno != EAGAIN && errno != EWOULDBLOCK))) {
lru_crawler_close_client(c);
return -1;
@@ -304,7 +304,7 @@ static int lru_crawler_poll(crawler_client_t *c) {
lru_crawler_close_client(c);
return -1;
} else if (to_poll[0].revents & POLLOUT) {
- int total = write(c->sfd, data, data_size);
+ int total = ((conn*)c->c)->write(c->c, data, data_size);
if (total == -1) {
if (errno != EAGAIN && errno != EWOULDBLOCK) {
lru_crawler_close_client(c);