Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changes/stack-overflow-release-build.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"tauri": "patch:bug"
"tauri-macros": "patch:bug"
---

Fix the stack overflow when having too many commands in a single invoke handler in release build
3 changes: 1 addition & 2 deletions crates/tauri-macros/src/command/wrapper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -283,10 +283,9 @@ pub fn wrapper(attributes: TokenStream, item: TokenStream) -> TokenStream {
macro_rules! #wrapper {
// double braces because the item is expected to be a block expression
($path:path, $invoke:ident) => {
// The IIFE here is for preventing stack overflow on Windows debug build,
// The IIFE here is for preventing stack overflow on Windows,
// see https://github.com/tauri-apps/tauri/issues/12488
{
#[cfg_attr(not(debug_assertions), inline(always))]
move || {
#[allow(unused_imports)]
use #root::ipc::private::*;
Expand Down
Loading