aboutsummaryrefslogtreecommitdiff
path: root/azalea-client
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2024-04-20 04:03:03 +0000
committermat <git@matdoes.dev>2024-04-20 04:03:03 +0000
commit8a1e1b7bb93373e85432ce4211b6ede4eae79409 (patch)
treec2803f0a1a6c22c0e4ab0f123f662f817ed7aaff /azalea-client
parent6d9d1a456951ae321089343a91d15bfa9f3087d7 (diff)
downloadazalea-drasl-8a1e1b7bb93373e85432ce4211b6ede4eae79409.tar.xz
clippy
Diffstat (limited to 'azalea-client')
-rw-r--r--azalea-client/src/packet_handling/game.rs2
-rw-r--r--azalea-client/src/task_pool.rs4
2 files changed, 3 insertions, 3 deletions
diff --git a/azalea-client/src/packet_handling/game.rs b/azalea-client/src/packet_handling/game.rs
index 30b736c0..1c913ba5 100644
--- a/azalea-client/src/packet_handling/game.rs
+++ b/azalea-client/src/packet_handling/game.rs
@@ -557,7 +557,7 @@ pub fn process_packet_events(ecs: &mut World) {
info.latency = updated_info.latency;
}
if p.actions.update_display_name {
- info.display_name = updated_info.display_name.clone();
+ info.display_name.clone_from(&updated_info.display_name);
}
update_player_events.send(UpdatePlayerEvent {
entity: player_entity,
diff --git a/azalea-client/src/task_pool.rs b/azalea-client/src/task_pool.rs
index da1de607..d4963cd5 100644
--- a/azalea-client/src/task_pool.rs
+++ b/azalea-client/src/task_pool.rs
@@ -58,7 +58,7 @@ impl Default for TaskPoolOptions {
TaskPoolOptions {
// By default, use however many cores are available on the system
min_total_threads: 1,
- max_total_threads: std::usize::MAX,
+ max_total_threads: usize::MAX,
// Use 25% of cores for IO, at least 1, no more than 4
io: TaskPoolThreadAssignmentPolicy {
@@ -77,7 +77,7 @@ impl Default for TaskPoolOptions {
// Use all remaining cores for compute (at least 1)
compute: TaskPoolThreadAssignmentPolicy {
min_threads: 1,
- max_threads: std::usize::MAX,
+ max_threads: usize::MAX,
percent: 1.0, // This 1.0 here means "whatever is left over"
},
}