From 6188872fbc38cd38a3f2e909d9b4fe27473a8f67 Mon Sep 17 00:00:00 2001 From: chenjiayi Date: Tue, 21 Nov 2023 20:06:29 +0800 Subject: [PATCH 078/103] fix(device): keep consistent on the base path for db cloned device object The db cloned device object should collect data from the same base path with the original device object. --- libs/device/src/device.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libs/device/src/device.rs b/libs/device/src/device.rs index b8507fe0..e8e2dcc5 100644 --- a/libs/device/src/device.rs +++ b/libs/device/src/device.rs @@ -2390,6 +2390,8 @@ impl Device { pub fn shallow_clone(&self) -> Result { let device = Self::default(); + device.set_base_path(self.base_path.borrow().as_str()); + let syspath = self.get_syspath()?; device.set_syspath(&syspath, false)?; -- 2.33.0