added functionality to open shared files with you + fixed bug where mid transfer the SIGTERM signal can corrupt the mount

This commit is contained in:
nvrl committed 2026-07-20 22:30:16 +02:00
1 parent e0f0c7e0b7
commit bf625bf8d9
15 files changed
+1621 -136

No files matched your search

+6 -5
View File
@@ -137,9 +137,10 @@ impl Db {
if exists.is_none() {
continue;
}
let count: i64 = conn.query_row(&format!("SELECT count(*) FROM \"{name}\""), [], |r| {
r.get(0)
})?;
let count: i64 =
conn.query_row(&format!("SELECT count(*) FROM \"{name}\""), [], |r| {
r.get(0)
})?;
tables.push(((*name).to_string(), count));
}
@@ -203,7 +204,6 @@ impl Db {
let frames: i64 = conn.query_row("PRAGMA wal_checkpoint(TRUNCATE)", [], |r| r.get(2))?;
Ok(frames.max(0))
}
}
#[cfg(test)]
@@ -314,7 +314,8 @@ mod tests {
let db = Db::open(&path).unwrap();
for i in 0..2000 {
db.set_state_str(&format!("k{i}"), &"v".repeat(256)).unwrap();
db.set_state_str(&format!("k{i}"), &"v".repeat(256))
.unwrap();
}
let full = db.stats().unwrap().total_bytes();
for i in 0..2000 {