Skip to content

Fix a missing increment in p1-to-p2 adapter#10064

Merged
alexcrichton merged 1 commit intobytecodealliance:mainfrom
alexcrichton:fix-preopen-path-
Jan 21, 2025
Merged

Fix a missing increment in p1-to-p2 adapter#10064
alexcrichton merged 1 commit intobytecodealliance:mainfrom
alexcrichton:fix-preopen-path-

Conversation

@alexcrichton
Copy link
Member

This commit fixes a bug in the WASIp1-to-WASIp2 adapter during fd_prestat_dir_name where an iterator variable was forgotten to be incremented. That means that getting the path for anything other than the first preopen didn't work correctly.

Closes #10058

This commit fixes a bug in the WASIp1-to-WASIp2 adapter during
`fd_prestat_dir_name` where an iterator variable was forgotten to be
incremented. That means that getting the path for anything other than
the first preopen didn't work correctly.

Closes bytecodealliance#10058
@alexcrichton
Copy link
Member Author

On merging I'm going to backport this to a 29.0.1 release and then use that release to propagate the update of the adapter binary into various bits and pieces of tooling (e.g. wasm-component-ld, rustc, wasi-sdk, cargo-component, etc.)

@alexcrichton alexcrichton added this pull request to the merge queue Jan 21, 2025
Copy link
Contributor

@pchickey pchickey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

C programming, even with Rust syntax, strikes again. Thanks for fixing so quickly. Agree we should patch release where we can.

@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 21, 2025
@alexcrichton alexcrichton added this pull request to the merge queue Jan 21, 2025
Merged via the queue into bytecodealliance:main with commit 7ba0347 Jan 21, 2025
39 checks passed
@alexcrichton alexcrichton deleted the fix-preopen-path- branch January 21, 2025 18:30
alexcrichton added a commit to alexcrichton/wasmtime that referenced this pull request Jan 21, 2025
This commit fixes a bug in the WASIp1-to-WASIp2 adapter during
`fd_prestat_dir_name` where an iterator variable was forgotten to be
incremented. That means that getting the path for anything other than
the first preopen didn't work correctly.

Closes bytecodealliance#10058
alexcrichton added a commit that referenced this pull request Jan 21, 2025
* Add audit for `wasmtime-math` (#10059)

I noticed that CI is failing given that an audit and policy for
`wasmtime-math` is missing.

`wasmtime-math` was introduced in
https://github.com/bytecodealliance/wasmtime/pull/9808/files.

I followed a similar approach to what it's used for all the other
`wasmtime-*` crates.

* Fix a missing increment in p1-to-p2 adapter (#10064)

This commit fixes a bug in the WASIp1-to-WASIp2 adapter during
`fd_prestat_dir_name` where an iterator variable was forgotten to be
incremented. That means that getting the path for anything other than
the first preopen didn't work correctly.

Closes #10058

* Downgrade `wasip2` dep to 0.13.0

Compat with 1.81.0 MSRV

---------

Co-authored-by: Saúl Cabrera <saulecabrera@gmail.com>
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.

wasmtime-wasi only preopening the first and last directory set in WasiCtxBuilder

4 participants