mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-10 03:16:17 +01:00
gio: Bump copy buffer size to 256k by default
This is small enough that it shouldn't cause problems on most machines we support, but big enough to increase throughput on a lot of devices and network protocols. Note that the actual value is 256k minus malloc overhead, so that it fits nicely in a 256k block (as suggested by Alexander Larsson). See https://bugzilla.gnome.org/show_bug.cgi?id=773632 https://bugzilla.gnome.org/show_bug.cgi?id=773823
This commit is contained in:
parent
0106a6cd9e
commit
3b5b5696ed
@ -2765,7 +2765,8 @@ g_file_copy_attributes (GFile *source,
|
||||
return res;
|
||||
}
|
||||
|
||||
#define STREAM_BUFFER_SIZE (1024*64)
|
||||
/* 256k minus malloc overhead */
|
||||
#define STREAM_BUFFER_SIZE (1024*256 - 2 *sizeof(gpointer))
|
||||
|
||||
static gboolean
|
||||
copy_stream_with_progress (GInputStream *in,
|
||||
|
Loading…
Reference in New Issue
Block a user