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

Invalid free when requesting the same url twice #8

Closed
krichprollsch opened this issue Nov 29, 2024 · 0 comments · Fixed by #10
Closed

Invalid free when requesting the same url twice #8

krichprollsch opened this issue Nov 29, 2024 · 0 comments · Fixed by #10
Labels
bug Something isn't working

Comments

@krichprollsch
Copy link
Member

Calling client.async_open twice with the same url throw a async_open error.
Full stack: https://gist.github.com/krichprollsch/383af3bb23f376534832cd1a0039f455

thread 772351 panic: Invalid free
/usr/local/zig-0.13.0/lib/std/heap/general_purpose_allocator.zig:652:21: 0x125368c in freeLarge (test)
                    @panic("Invalid free");
                    ^
/usr/local/zig-0.13.0/lib/std/heap/general_purpose_allocator.zig:840:31: 0x124ab24 in free (test)
                self.freeLarge(old_mem, log2_old_align, ret_addr);
                              ^
/usr/local/zig-0.13.0/lib/std/mem/Allocator.zig:98:28: 0x136c139 in destroy__anon_18379 (test)
    return self.vtable.free(self.ptr, buf, log2_buf_align, ret_addr);
                           ^
/home/pierre/wrk/zig-async-io/src/std/http/Client.zig:1700:43: 0x12b417a in setConnection (test)
    defer ctx.req.client.allocator.destroy(old_conn);
                                          ^
/home/pierre/wrk/zig-async-io/src/std/http/Client.zig:2460:13: 0x12506de in pop (test)
            return @call(.auto, func, .{ self, res });
            ^
/home/pierre/wrk/zig-async-io/src/std/net.zig:2008:19: 0x136c25c in onTcpConnectToHost (test)
    return ctx.pop({});
                  ^
/home/pierre/wrk/zig-async-io/src/std/http/Client.zig:2460:13: 0x12506de in pop (test)
            return @call(.auto, func, .{ self, res });
            ^
@krichprollsch krichprollsch added the bug Something isn't working label Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant