cool.io icon indicating copy to clipboard operation
cool.io copied to clipboard

Use xfree() for heap area allocated by xmalloc

Open Watson1978 opened this issue 2 months ago • 0 comments

In buffer.c, it uses xmalloc Ruby API to allocate heap area.

  • https://github.com/socketry/cool.io/blob/6f85a2a104488e5c7cb128b9a83058d28ba16d37/ext/cool.io/buffer.c#L445
  • https://github.com/socketry/cool.io/blob/6f85a2a104488e5c7cb128b9a83058d28ba16d37/ext/cool.io/buffer.c#L509

To release the areas, it should use xfree instead of free.

Types of Changes

  • Bug fix.

Contribution

Watson1978 avatar Oct 28 '25 09:10 Watson1978