diff options
author | Mole Shang <[email protected]> | 2023-08-10 14:15:00 +0800 |
---|---|---|
committer | Mole Shang <[email protected]> | 2023-08-10 14:15:00 +0800 |
commit | 6cbcaba2a80c47714e8aa45d021bdcd4965780b1 (patch) | |
tree | 0adcb9b088997689e18fad20a463ea681e4f50b7 /src/process_url.c | |
parent | ef4918ffeb326751fa17c2c8335963be4e43254f (diff) | |
download | hinata-6cbcaba2a80c47714e8aa45d021bdcd4965780b1.tar.gz hinata-6cbcaba2a80c47714e8aa45d021bdcd4965780b1.tar.bz2 hinata-6cbcaba2a80c47714e8aa45d021bdcd4965780b1.zip |
ui: show progress while remuxing
Diffstat (limited to 'src/process_url.c')
-rw-r--r-- | src/process_url.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/process_url.c b/src/process_url.c index 713e48c..9b1fa86 100644 --- a/src/process_url.c +++ b/src/process_url.c @@ -522,14 +522,15 @@ void poll_status(status_t *stat) { DEBUG_PRINT("Creating download task failed.\n"); }; stat->is_done = false; + stat->type = SIZE_BYTES; } if (curl_conf) { curl_conf->dlnow = 0L; for (unsigned char i = 0; i < curl_conf->total_thrd; i++) { curl_conf->dlnow += curl_conf->dlnow_per_thrd[i]; } - stat->cur = curl_conf->dlnow; - stat->total = curl_conf->dltotal; + stat->cur = (unsigned long)curl_conf->dlnow; + stat->total = (unsigned long)curl_conf->dltotal; DEBUG_PRINT("success_thrd: %hhu, total_thrd: %hhu, is_done: %s\n", curl_conf->success_thrd, curl_conf->total_thrd, stat->is_done ? "yes" : "no"); |