From 11e2837ec51bf2248b7163c48fef9229294646d6 Mon Sep 17 00:00:00 2001 From: Pavel Ivanov Date: Sun, 26 Nov 2023 12:10:34 +0100 Subject: [PATCH] new: updated capnp to version 0.18.7 --- Cargo.lock | 19 ++++++++++++++----- Cargo.toml | 6 +++--- src/index.rs | 4 ++-- 3 files changed, 19 insertions(+), 10 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 64c6fea0..b81119a8 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -217,15 +217,18 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "capnp" -version = "0.17.2" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95e65021d89250bbfe7c2791789ced2c4bdc21b0e8bb59c64f3fd6145a5fd678" +checksum = "ce3a3a3b1b6ad38dea0e945a9bc1524331b03ba1d07360bd437891fc86e14091" +dependencies = [ + "embedded-io", +] [[package]] name = "capnpc" -version = "0.17.2" +version = "0.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbbc3763fb3e6635188e9cc51ee11a26f8777c553ca377430818dbebaaf6042b" +checksum = "5067f3c8ee94d993d03150153e9a57a6ff330127b1c1ad76475051e1cef79c2d" dependencies = [ "capnp", ] @@ -577,6 +580,12 @@ version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +[[package]] +name = "embedded-io" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "658bbadc628dc286b9ae02f0cb0f5411c056eb7487b72f0083203f115de94060" + [[package]] name = "enum-map" version = "2.7.0" @@ -728,7 +737,7 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] name = "hl" -version = "0.20.1-alpha.1" +version = "0.20.1-alpha.2" dependencies = [ "atoi", "bincode", diff --git a/Cargo.toml b/Cargo.toml index af7dac92..136301e9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,12 +4,12 @@ categories = ["command-line-utilities"] description = "Utility for viewing json-formatted log files." keywords = ["cli", "human", "log"] name = "hl" -version = "0.20.1-alpha.1" +version = "0.20.1-alpha.2" edition = "2021" build = "build.rs" [build-dependencies] -capnpc = "0.17" +capnpc = "0.18" generic-array = "0" hex = "0" serde = { version = "1", features = ["derive"] } @@ -22,7 +22,7 @@ atoi = "1" bincode = "1" bitmask = "0" bytefmt = "0" -capnp = "0.17" +capnp = "0.18" chrono = { version = "0.4", default-features = false, features = ["clock", "serde", "std"] } chrono-tz = { version = "0", features = ["serde"] } clap = {version = "4", features = ["wrap_help", "derive", "env"]} diff --git a/src/index.rs b/src/index.rs index da403426..98c00f1f 100644 --- a/src/index.rs +++ b/src/index.rs @@ -409,7 +409,7 @@ impl Index { Ok(Index { source: SourceFile { size: source.get_size(), - path: source.get_path()?.into(), + path: source.get_path()?.to_string()?, modified: (modified.get_sec(), modified.get_nsec()), stat: Self::load_stat(source.get_index()?), blocks: Self::load_blocks(source)?, @@ -425,7 +425,7 @@ impl Index { let root: schema::root::Builder = message.init_root(); let mut source = root.init_source(); source.set_size(self.source.size); - source.set_path(&self.source.path); + source.set_path(self.source.path.as_bytes().into()); let mut modified = source.reborrow().init_modified(); modified.set_sec(self.source.modified.0); modified.set_nsec(self.source.modified.1);