[gvfs/gnome-3-22] daemon: Bump maximum read channel buffer size
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gvfs/gnome-3-22] daemon: Bump maximum read channel buffer size
- Date: Tue, 3 Jan 2017 12:34:58 +0000 (UTC)
commit 0ecac6bb2ee67c788abacadebd7bd3be3b665855
Author: Bastien Nocera <hadess hadess net>
Date: Wed Nov 2 12:51:23 2016 +0100
daemon: Bump maximum read channel buffer size
256k isn't in the "stupid" buffer size for network reads, so bump the
maximum size of the read buffer.
See https://bugzilla.gnome.org/show_bug.cgi?id=773632
See https://bugzilla.gnome.org/show_bug.cgi?id=773823
https://bugzilla.gnome.org/show_bug.cgi?id=773826
daemon/gvfsreadchannel.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/daemon/gvfsreadchannel.c b/daemon/gvfsreadchannel.c
index f219ded..b6b6a93 100644
--- a/daemon/gvfsreadchannel.c
+++ b/daemon/gvfsreadchannel.c
@@ -118,16 +118,18 @@ modify_read_size (GVfsReadChannel *channel,
real_size = 16*1024;
else if (channel->read_count <= 4)
real_size = 32*1024;
- else
+ else if (channel->read_count <= 5)
real_size = 64*1024;
+ else
+ real_size = 128*1024;
if (requested_size > real_size)
real_size = requested_size;
/* Don't do ridicoulously large requests as this
is just stupid on the network */
- if (real_size > 128 * 1024)
- real_size = 128 * 1024;
+ if (real_size > 256 * 1024)
+ real_size = 256 * 1024;
return real_size;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]