summaryrefslogtreecommitdiff
path: root/src/trg-client.h
diff options
context:
space:
mode:
authorGravatar Alan Fitton <ajf@eth0.org.uk>2011-11-30 18:54:29 +0000
committerGravatar Alan Fitton <ajf@eth0.org.uk>2011-11-30 18:54:29 +0000
commit7bc8fe632f29a875659f223ad1e9aa035c56f46c (patch)
tree8a13af1000337feade93762295b213283b03d089 /src/trg-client.h
parent6df6b7c2a2383d01a6fc20e597f48b0168ccfeb5 (diff)
add some comments at the top of some files, also add a timeout of 20 seconds for curl requests
Diffstat (limited to 'src/trg-client.h')
-rw-r--r--src/trg-client.h27
1 files changed, 13 insertions, 14 deletions
diff --git a/src/trg-client.h b/src/trg-client.h
index cf3e04f..31a9267 100644
--- a/src/trg-client.h
+++ b/src/trg-client.h
@@ -22,6 +22,19 @@
#ifndef _TRG_CLIENT_H_
#define _TRG_CLIENT_H_
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include <curl/curl.h>
+#include <curl/easy.h>
+
+#include <json-glib/json-glib.h>
+#include <glib-object.h>
+
+#include "trg-prefs.h"
+#include "session-get.h"
+
#define TRANSMISSION_MIN_SUPPORTED 2.0
#define X_TRANSMISSION_SESSION_ID_HEADER_PREFIX "X-Transmission-Session-Id: "
#define TRG_MAX_RETRIES 3
@@ -37,19 +50,6 @@
#define TRG_NO_HOSTNAME_SET -2
#define SESSION_UPDATE_DIVISOR 10
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <curl/curl.h>
-#include <curl/easy.h>
-
-#include <json-glib/json-glib.h>
-#include <glib-object.h>
-
-#include "trg-prefs.h"
-#include "session-get.h"
-
#define HTTP_URI_PREFIX "http"
#define HTTPS_URI_PREFIX "https"
#define HTTP_OK 200
@@ -59,7 +59,6 @@
#define FAIL_RESPONSE_UNSUCCESSFUL -3
#define DISPATCH_POOL_SIZE 3
-
typedef struct {
int status;
int size;