Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix panic when Wasm input is too large #218

Merged
merged 2 commits into from
Feb 22, 2023

Conversation

tomaka
Copy link
Contributor

@tomaka tomaka commented Feb 22, 2023

The allocator makes sure to the grow memory for its own metadata, but doesn't necessarily grow the memory enough for the allocated data to fit.

@github-actions
Copy link

github-actions bot commented Feb 22, 2023

twiggy diff report

Difference in .wasm size before and after this pull request.


 Delta Bytes │ Item
─────────────┼──────────────────────────────────────────────────────────────────────────
         +93 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::h86121a026f2add57
         +93 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::hbb493c299af20e51
         +93 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::he720b7a3dc7b06b5
         +91 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::ha1a07bab01fc5d71
         +77 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::h8595c20e12de4f03
         +75 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::h35f29a13e3b7f384
         +75 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::hdcf84ffc0c960bc8
         +70 ┊ smoldot::executor::host::HostVmPrototype::run_vectored::h1175c97123f4cbc4
         +32 ┊ data[0]
          +6 ┊ nom::combinator::all_consuming::h8f748b8b1a1d61d2
          -4 ┊ core::result::Result<T,E>::unwrap::h516f9048a2509f4c
          +1 ┊ elem[0]
        +760 ┊ Σ [12 Total Rows]

@tomaka tomaka added this pull request to the merge queue Feb 22, 2023
Merged via the queue into smol-dot:main with commit 31a3daf Feb 22, 2023
@tomaka tomaka deleted the fix-panic-wasm-input branch February 22, 2023 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant