diff options
author | Robert Pösel <robyer@seznam.cz> | 2016-09-04 14:04:49 +0000 |
---|---|---|
committer | Robert Pösel <robyer@seznam.cz> | 2016-09-04 14:04:49 +0000 |
commit | 8234832e06e873df035270f162d7d151fbf6e7eb (patch) | |
tree | 200613059ddb4bc61c73fa946ca735836ee92163 /protocols/FacebookRM/src/client.h | |
parent | 2f492f0c3af53dada6b909d1c31dc665c33dfde5 (diff) |
Facebook: Massive rewrite of all communication requests
Note it doesn't use persistent connection yet.
git-svn-id: http://svn.miranda-ng.org/main/trunk@17246 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/FacebookRM/src/client.h')
-rw-r--r-- | protocols/FacebookRM/src/client.h | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/protocols/FacebookRM/src/client.h b/protocols/FacebookRM/src/client.h index 22297ebf26..14af119921 100644 --- a/protocols/FacebookRM/src/client.h +++ b/protocols/FacebookRM/src/client.h @@ -146,18 +146,18 @@ public: // Helpers for data
- std::string __inline __dyn() {
+ __inline const char *__dyn() {
return ""; // FIXME: What's this value and where it come from? Looks like it is the same through all requests.
}
- std::string __inline __req() {
+ __inline const char *__req() {
// Increment request number and convert it to string with radix 36 (whole numbers + whole alphabet)
char buffer[10];
itoa(InterlockedIncrement(&this->chat_req_), buffer, 36);
- return std::string(buffer);
+ return ptrA(mir_strdup(buffer));
}
- std::string __inline __rev() {
+ __inline const char *__rev() {
return "2509236"; // FIXME: Some version of communication protocol? This version is from 17.8.2016
}
@@ -208,15 +208,9 @@ public: // HTTP communication
- http::response flap(RequestType request_type, std::string *post_data = NULL, std::string *get_data = NULL);
+ http::response sendRequest(HttpRequest *request);
bool save_url(const std::string &url,const std::wstring &filename, HANDLE &nlc);
- bool notify_errors(RequestType);
- std::string choose_server(RequestType);
- std::string choose_action(RequestType, std::string *get_data = NULL);
-
- NETLIBHTTPHEADER *get_request_headers(int request_type, int *headers_count);
-
////////////////////////////////////////////////////////////
// Netlib handle
|