Skip to content

winio: fix array splat

Tamar Christina requested to merge Phyx/ghc:winio-fix-splat into master

Hi,

This fixes two issues with unsafeCopyFromBuffer:

  1. the bounds check should be exclusive not inclusive. This is causing it to bottom out when it shouldn't.
  2. memcpy takes number of bytes to copy, not number of elements.

Without these changes the function is incorrect and results in corrupted I/O records.

Ok for master and GHC 9?

Merge request reports