aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEsther1024 <danishreyjavik@outlook.com>2025-05-19 19:11:06 +0000
committercrueter <crueter@noreply.localhost>2025-05-19 19:11:06 +0000
commitea7b9519c7a5b3f27f16a1be9550ca69aa2d308b (patch)
tree4b9ec78a4314cf3e704a635aeba440cdaf915adb /src
parenta776f5bc3b04490fc1c6cfff15e2862e092beea5 (diff)
fix uninit values in applet and mouse (#114)
read before written; initialize so valgrind stops complaining Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/114 Co-authored-by: Esther1024 <danishreyjavik@outlook.com> Co-committed-by: Esther1024 <danishreyjavik@outlook.com>
Diffstat (limited to 'src')
-rw-r--r--src/hid_core/resources/applet_resource.h2
-rw-r--r--src/input_common/drivers/mouse.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/hid_core/resources/applet_resource.h b/src/hid_core/resources/applet_resource.h
index 4a5416fb29..69ea46b957 100644
--- a/src/hid_core/resources/applet_resource.h
+++ b/src/hid_core/resources/applet_resource.h
@@ -119,7 +119,7 @@ private:
std::array<AruidData, AruidIndexMax> data{};
std::array<SharedMemoryHolder, AruidIndexMax> shared_memory_holder{};
s32 ref_counter{};
- u64 active_vibration_aruid;
+ u64 active_vibration_aruid = 0;
Core::System& system;
};
diff --git a/src/input_common/drivers/mouse.h b/src/input_common/drivers/mouse.h
index 2b93a40b9c..124b6f3bd5 100644
--- a/src/input_common/drivers/mouse.h
+++ b/src/input_common/drivers/mouse.h
@@ -108,7 +108,7 @@ private:
Common::Vec2<float> last_mouse_change;
Common::Vec3<float> last_motion_change;
Common::Vec2<int> wheel_position;
- bool button_pressed;
+ bool button_pressed = false;
std::jthread update_thread;
};