mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-26 07:46:21 +02:00
Warn if the download buffer is full
This commit is contained in:
parent
8ffea0a018
commit
f6a9a71b38
1 changed files with 2 additions and 0 deletions
|
@ -860,6 +860,8 @@ void FileTransfer::download(
|
||||||
sender.) */
|
sender.) */
|
||||||
if (state->data.size() > fileTransferSettings.downloadBufferSize) {
|
if (state->data.size() > fileTransferSettings.downloadBufferSize) {
|
||||||
debug("download buffer is full; going to sleep");
|
debug("download buffer is full; going to sleep");
|
||||||
|
static bool haveWarned = false;
|
||||||
|
warnOnce(haveWarned, "download buffer is full; consider increasing the 'download-buffer-size' setting");
|
||||||
state.wait_for(state->request, std::chrono::seconds(10));
|
state.wait_for(state->request, std::chrono::seconds(10));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue