drupflare/worker - v1.0.0
    Preparing search index...

    Function replayStreams

    • Reopens each captured descriptor AT THE SAME fd NUMBER.

      FS.open() returns the next free descriptor, which is not necessarily the one the image expects, so the stream is relocated afterwards and the vacated slot nulled.

      The numeric flags go back in as-is: they came out of a real open, and the node ops then see exactly the mode PHP opened with. Measured without this -- dropping /dev/urandom alone throws RandomException, and dropping the three sqlite descriptors gives a locking-protocol error after an 80-120 second stall, which on the edge is a hung request rather than an error. That is why failures are collected and returned rather than thrown past: the caller must be able to refuse the restore BEFORE the memcpy, naming every bad descriptor at once.

      Parameters

      Returns ReplayResult