aboutsummaryrefslogtreecommitdiff
path: root/backends/networking
diff options
context:
space:
mode:
Diffstat (limited to 'backends/networking')
-rw-r--r--backends/networking/curl/networkreadstream.cpp6
-rw-r--r--backends/networking/curl/networkreadstream.h6
2 files changed, 6 insertions, 6 deletions
diff --git a/backends/networking/curl/networkreadstream.cpp b/backends/networking/curl/networkreadstream.cpp
index d761cbb5aa..5c3730645b 100644
--- a/backends/networking/curl/networkreadstream.cpp
+++ b/backends/networking/curl/networkreadstream.cpp
@@ -47,7 +47,7 @@ static size_t curlHeadersCallback(char *d, size_t n, size_t l, void *p) {
return 0;
}
-void NetworkReadStream::init(const char *url, curl_slist *headersList, byte *buffer, uint32 bufferSize, bool uploading, bool usingPatch, bool post) {
+void NetworkReadStream::init(const char *url, curl_slist *headersList, const byte *buffer, uint32 bufferSize, bool uploading, bool usingPatch, bool post) {
_eos = _requestComplete = false;
_sendingContentsBuffer = nullptr;
_sendingContentsSize = _sendingContentsPos = 0;
@@ -81,10 +81,10 @@ void NetworkReadStream::init(const char *url, curl_slist *headersList, byte *buf
}
NetworkReadStream::NetworkReadStream(const char *url, curl_slist *headersList, Common::String postFields, bool uploading, bool usingPatch) {
- init(url, headersList, (byte *)postFields.c_str(), postFields.size(), uploading, usingPatch, false);
+ init(url, headersList, (const byte *)postFields.c_str(), postFields.size(), uploading, usingPatch, false);
}
-NetworkReadStream::NetworkReadStream(const char *url, curl_slist *headersList, byte *buffer, uint32 bufferSize, bool uploading, bool usingPatch, bool post) {
+NetworkReadStream::NetworkReadStream(const char *url, curl_slist *headersList, const byte *buffer, uint32 bufferSize, bool uploading, bool usingPatch, bool post) {
init(url, headersList, buffer, bufferSize, uploading, usingPatch, post);
}
diff --git a/backends/networking/curl/networkreadstream.h b/backends/networking/curl/networkreadstream.h
index 7a9d9ff0d1..6f521cbc4b 100644
--- a/backends/networking/curl/networkreadstream.h
+++ b/backends/networking/curl/networkreadstream.h
@@ -35,15 +35,15 @@ namespace Networking {
class NetworkReadStream: public Common::MemoryReadWriteStream {
CURL *_easy;
bool _eos, _requestComplete;
- byte *_sendingContentsBuffer;
+ const byte *_sendingContentsBuffer;
uint32 _sendingContentsSize;
uint32 _sendingContentsPos;
Common::String _responseHeaders;
- void init(const char *url, curl_slist *headersList, byte *buffer, uint32 bufferSize, bool uploading, bool usingPatch, bool post);
+ void init(const char *url, curl_slist *headersList, const byte *buffer, uint32 bufferSize, bool uploading, bool usingPatch, bool post);
public:
NetworkReadStream(const char *url, curl_slist *headersList, Common::String postFields, bool uploading = false, bool usingPatch = false);
- NetworkReadStream(const char *url, curl_slist *headersList, byte *buffer, uint32 bufferSize, bool uploading = false, bool usingPatch = false, bool post = true);
+ NetworkReadStream(const char *url, curl_slist *headersList, const byte *buffer, uint32 bufferSize, bool uploading = false, bool usingPatch = false, bool post = true);
virtual ~NetworkReadStream();
/**