From bebce03f4a364efc960c19abeb08640620f65078 Mon Sep 17 00:00:00 2001 From: Pierre Krieger Date: Tue, 28 Feb 2023 17:25:18 +0100 Subject: [PATCH 1/2] Fix two wrong host function signatures --- lib/src/executor/host.rs | 4 ++-- wasm-node/CHANGELOG.md | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/src/executor/host.rs b/lib/src/executor/host.rs index 7d147b774c..daedc42c57 100644 --- a/lib/src/executor/host.rs +++ b/lib/src/executor/host.rs @@ -4092,7 +4092,7 @@ impl HostFunction { crate::signature!((vm::ValueType::I64, vm::ValueType::I64) => vm::ValueType::I64) } HostFunction::ext_default_child_storage_read_version_1 => { - crate::signature!((vm::ValueType::I64, vm::ValueType::I64, vm::ValueType::I64, vm::ValueType::I64) => vm::ValueType::I64) + crate::signature!((vm::ValueType::I64, vm::ValueType::I64, vm::ValueType::I64, vm::ValueType::I32) => vm::ValueType::I64) } HostFunction::ext_default_child_storage_storage_kill_version_1 => { crate::signature!((vm::ValueType::I64) => ()) @@ -4125,7 +4125,7 @@ impl HostFunction { crate::signature!((vm::ValueType::I64) => vm::ValueType::I64) } HostFunction::ext_default_child_storage_root_version_2 => { - crate::signature!((vm::ValueType::I64, vm::ValueType::I32) => vm::ValueType::I32) + crate::signature!((vm::ValueType::I64, vm::ValueType::I32) => vm::ValueType::I64) } HostFunction::ext_crypto_ed25519_public_keys_version_1 => { crate::signature!((vm::ValueType::I32) => vm::ValueType::I64) diff --git a/wasm-node/CHANGELOG.md b/wasm-node/CHANGELOG.md index e04d512b1d..48a74e3048 100644 --- a/wasm-node/CHANGELOG.md +++ b/wasm-node/CHANGELOG.md @@ -12,6 +12,7 @@ ## Fixed +- Fix the signatures of the `ext_default_child_storage_read_version_1` and `ext_default_child_storage_root_version_2` host functions. This would lead to a warning about these function being unresolved. - Fix panic when the input data of a Wasm function call is larger than a Wasm page. ([#218](https://github.com/smol-dot/smoldot/pull/218)) - Subscriptions to the `chain_subscribeAllHeads` JSON-RPC function now generate notifications named `chain_allHead`, like in Substrate. They were erroneously named `chain_newHead`. ([#227](https://github.com/smol-dot/smoldot/pull/227)) From b65975a4c1fe08f51c6bd99fca1ce46bc5be640d Mon Sep 17 00:00:00 2001 From: Pierre Krieger Date: Tue, 28 Feb 2023 17:28:14 +0100 Subject: [PATCH 2/2] PR link --- wasm-node/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wasm-node/CHANGELOG.md b/wasm-node/CHANGELOG.md index 48a74e3048..32b03aa4fc 100644 --- a/wasm-node/CHANGELOG.md +++ b/wasm-node/CHANGELOG.md @@ -12,7 +12,7 @@ ## Fixed -- Fix the signatures of the `ext_default_child_storage_read_version_1` and `ext_default_child_storage_root_version_2` host functions. This would lead to a warning about these function being unresolved. +- Fix the signatures of the `ext_default_child_storage_read_version_1` and `ext_default_child_storage_root_version_2` host functions. This would lead to a warning about these function being unresolved. ([#244](https://github.com/smol-dot/smoldot/pull/244)) - Fix panic when the input data of a Wasm function call is larger than a Wasm page. ([#218](https://github.com/smol-dot/smoldot/pull/218)) - Subscriptions to the `chain_subscribeAllHeads` JSON-RPC function now generate notifications named `chain_allHead`, like in Substrate. They were erroneously named `chain_newHead`. ([#227](https://github.com/smol-dot/smoldot/pull/227))