summaryrefslogtreecommitdiff
path: root/hscript
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2020-05-26 22:51:46 -0500
committerA. Wilcox <AWilcox@Wilcox-Tech.com>2020-05-26 22:51:46 -0500
commit667de5e4155dcfad6cb6fecf378a305aaf8e3393 (patch)
tree065f9013acba6516552c47b927a71c0392b22881 /hscript
parent883140073f1dcd29f20f0614246e5d00e505030d (diff)
downloadhorizon-667de5e4155dcfad6cb6fecf378a305aaf8e3393.tar.gz
horizon-667de5e4155dcfad6cb6fecf378a305aaf8e3393.tar.bz2
horizon-667de5e4155dcfad6cb6fecf378a305aaf8e3393.tar.xz
horizon-667de5e4155dcfad6cb6fecf378a305aaf8e3393.zip
hscript: Flush downloaded file before returning
Diffstat (limited to 'hscript')
-rw-r--r--hscript/util.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/hscript/util.cc b/hscript/util.cc
index 13688dd..8317995 100644
--- a/hscript/util.cc
+++ b/hscript/util.cc
@@ -52,6 +52,7 @@ bool download_file(const std::string &url, const std::string &path) {
result = curl_easy_perform(curl);
if(result == CURLE_OK) {
+ fflush(fp);
return_code = true;
} else {
output_error("curl", "couldn't download file", errbuf);