diff options
Diffstat (limited to 'plugins/http-files/src')
-rw-r--r-- | plugins/http-files/src/file_provider.vala | 4 | ||||
-rw-r--r-- | plugins/http-files/src/file_sender.vala | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/plugins/http-files/src/file_provider.vala b/plugins/http-files/src/file_provider.vala index 3a3aeb94..7928dc81 100644 --- a/plugins/http-files/src/file_provider.vala +++ b/plugins/http-files/src/file_provider.vala @@ -101,7 +101,7 @@ public class FileProvider : Dino.FileProvider, Object { head_message.request_headers.append("Accept-Encoding", "identity"); try { -#if SOUP_3 +#if SOUP_3_0 yield session.send_async(head_message, GLib.Priority.LOW, null); #else yield session.send_async(head_message, null); @@ -136,7 +136,7 @@ public class FileProvider : Dino.FileProvider, Object { var get_message = new Soup.Message("GET", http_receive_data.url); try { -#if SOUP_3 +#if SOUP_3_0 InputStream stream = yield session.send_async(get_message, GLib.Priority.LOW, file_transfer.cancellable); #else InputStream stream = yield session.send_async(get_message, file_transfer.cancellable); diff --git a/plugins/http-files/src/file_sender.vala b/plugins/http-files/src/file_sender.vala index ab81ffce..a39d695b 100644 --- a/plugins/http-files/src/file_sender.vala +++ b/plugins/http-files/src/file_sender.vala @@ -73,7 +73,7 @@ public class HttpFileSender : FileSender, Object { } } -#if !SOUP_3 +#if !SOUP_3_0 private static void transfer_more_bytes(InputStream stream, Soup.MessageBody body) { uint8[] bytes = new uint8[4096]; ssize_t read = stream.read(bytes); @@ -93,7 +93,7 @@ public class HttpFileSender : FileSender, Object { var session = new Soup.Session(); session.user_agent = @"Dino/$(Dino.get_short_version()) "; var put_message = new Soup.Message("PUT", file_send_data.url_up); -#if SOUP_3 +#if SOUP_3_0 put_message.set_request_body(file_meta.mime_type, file_transfer.input_stream, (ssize_t) file_meta.size); #else put_message.request_headers.set_content_type(file_meta.mime_type, null); @@ -106,7 +106,7 @@ public class HttpFileSender : FileSender, Object { put_message.request_headers.append(entry.key, entry.value); } try { -#if SOUP_3 +#if SOUP_3_0 yield session.send_async(put_message, GLib.Priority.LOW, file_transfer.cancellable); #else yield session.send_async(put_message, file_transfer.cancellable); |