mirror of
https://github.com/Drop-OSS/drop-app.git
synced 2025-11-18 02:31:24 +10:00
refactor: Convert some things from static to const and refactor into drop-consts
Signed-off-by: quexeky <git@quexeky.dev>
This commit is contained in:
@ -15,6 +15,7 @@ use download_manager::util::download_thread_control_flag::{
|
||||
DownloadThreadControl, DownloadThreadControlFlag,
|
||||
};
|
||||
use download_manager::util::progress_object::ProgressHandle;
|
||||
use drop_consts::{BUMP_SIZE, MAX_PACKET_LENGTH};
|
||||
use log::{debug, info, warn};
|
||||
use md5::{Context, Digest};
|
||||
use remote::auth::generate_authorization_header;
|
||||
@ -25,9 +26,6 @@ use reqwest::blocking::Response;
|
||||
|
||||
use crate::downloads::manifest::{ChunkBody, DownloadBucket, DownloadContext, DownloadDrop};
|
||||
|
||||
static MAX_PACKET_LENGTH: usize = 4096 * 4;
|
||||
static BUMP_SIZE: usize = 4096 * 16;
|
||||
|
||||
pub struct DropWriter<W: Write> {
|
||||
hasher: Context,
|
||||
destination: BufWriter<W>,
|
||||
|
||||
Reference in New Issue
Block a user