#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <sys/time.h>
#include <time.h>
#include <unistd.h>
#include <sys/poll.h>
#include <curl/curl.h>
#include <event2/event.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>
Go to the source code of this file.
|
| #define | MSG_OUT stdout /* Send info to stdout, change to stderr if you want */ |
| |
|
| static void | addsock (curl_socket_t s, CURL *easy, int action, GlobalInfo *g) |
| |
| static void | check_multi_info (GlobalInfo *g) |
| |
| static void | clean_fifo (GlobalInfo *g) |
| |
| static void | event_cb (int fd, short kind, void *userp) |
| |
| static void | fifo_cb (int fd, short event, void *arg) |
| |
| static int | init_fifo (GlobalInfo *g) |
| |
| int | main (int argc, char **argv) |
| |
| static void | mcode_or_die (const char *where, CURLMcode code) |
| |
| static int | multi_timer_cb (CURLM *multi, long timeout_ms, GlobalInfo *g) |
| |
| static void | new_conn (char *url, GlobalInfo *g) |
| |
| static int | prog_cb (void *p, double dltotal, double dlnow, double ult, double uln) |
| |
| static void | remsock (SockInfo *f) |
| |
| static void | setsock (SockInfo *f, curl_socket_t s, CURL *e, int act, GlobalInfo *g) |
| |
| static int | sock_cb (CURL *e, curl_socket_t s, int what, void *cbp, void *sockp) |
| |
| static void | timer_cb (int fd, short kind, void *userp) |
| |
| static size_t | write_cb (void *ptr, size_t size, size_t nmemb, void *data) |
| |
|
| static const char * | fifo = "hiper.fifo" |
| |
◆ MSG_OUT
| #define MSG_OUT stdout /* Send info to stdout, change to stderr if you want */ |
◆ ConnInfo
◆ GlobalInfo
◆ SockInfo
◆ addsock()
◆ check_multi_info()
◆ clean_fifo()
◆ event_cb()
| static void event_cb |
( |
int |
fd, |
|
|
short |
kind, |
|
|
void * |
userp |
|
) |
| |
|
static |
◆ fifo_cb()
| static void fifo_cb |
( |
int |
fd, |
|
|
short |
event, |
|
|
void * |
arg |
|
) |
| |
|
static |
◆ init_fifo()
◆ main()
| int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
◆ mcode_or_die()
| static void mcode_or_die |
( |
const char * |
where, |
|
|
CURLMcode |
code |
|
) |
| |
|
static |
◆ multi_timer_cb()
| static int multi_timer_cb |
( |
CURLM * |
multi, |
|
|
long |
timeout_ms, |
|
|
GlobalInfo * |
g |
|
) |
| |
|
static |
◆ new_conn()
| static void new_conn |
( |
char * |
url, |
|
|
GlobalInfo * |
g |
|
) |
| |
|
static |
◆ prog_cb()
| static int prog_cb |
( |
void * |
p, |
|
|
double |
dltotal, |
|
|
double |
dlnow, |
|
|
double |
ult, |
|
|
double |
uln |
|
) |
| |
|
static |
◆ remsock()
◆ setsock()
◆ sock_cb()
◆ timer_cb()
| static void timer_cb |
( |
int |
fd, |
|
|
short |
kind, |
|
|
void * |
userp |
|
) |
| |
|
static |
◆ write_cb()
◆ fifo
| const char* fifo = "hiper.fifo" |
|
static |