1. 13 Sep, 2024 2 commits
  2. 12 Sep, 2024 5 commits
  3. 11 Sep, 2024 4 commits
  4. 10 Sep, 2024 2 commits
  5. 09 Sep, 2024 2 commits
    • Grégoire Locqueville's avatar
      Remove useless code, dependencies, warnings · 802e0cdf
      Grégoire Locqueville authored
      - Re-enable orphan warnings that were manually disabled in many modules
      - Remove non-Haskell files that were just sitting in the source tree
      - Remove modules that were not called from anywhere
      - Remove unused dependencies
      
      This is not exhaustive by any means. In particular, some more weeding out
      can be achieved by looking at individual functions and even branches of
      functions. Weeder can help with that.
      802e0cdf
    • Alexandre Delanoë's avatar
      [VERSION] +1 to 0.0.7.2.4 · 0b5ce744
      Alexandre Delanoë authored
      0b5ce744
  6. 05 Sep, 2024 8 commits
  7. 04 Sep, 2024 10 commits
  8. 03 Sep, 2024 5 commits
  9. 02 Sep, 2024 2 commits
    • Alfredo Di Napoli's avatar
      ws: remove calls to recvMalloc · 15b732f5
      Alfredo Di Napoli authored
      Remove the calls to `recvMalloc` in favour of using the (patched) `recv`
      from the original nanomsg library, which shouldn't segfault anymore. The
      reason for using `recv` are a few, but mostly the fact that `recv` can
      allocated arbitrary-long payloads data (up to the 1MB limit) without an
      hardcoded limit like `recvMalloc` was imposing. Furthermore, `recv` does
      resource cleanup for us via `c_nn_freemsg`, whereas `recvMalloc` is not
      thread/exception safe. Consider the implementation:
      
      ```
      recvMalloc :: Receiver a => Socket a -> Int -> IO ByteString
      recvMalloc (Socket t sid) numBytes = do
        ptr <- mallocBytes numBytes
        -- receive by blocking the thread
        len <- c_nn_recv sid ptr (#const NN_MSG) 0 -- (#const NN_DONTWAIT)
        str <- C.packCStringLen (castPtr ptr, fromIntegral len)
        free ptr
        return str
      ```
      
      If any exception (synchronous or asynchronous) strikes _before_ the call
      to `free`, we would be leaking C memory.
      15b732f5
    • Alfredo Di Napoli's avatar
      ws: make Dispatcher abstract · 7c0d6ba0
      Alfredo Di Napoli authored
      The `Dispatcher` type is now opaque and not exported by
      `.AsyncUpdates.Dispatcher`, and it has been moved out of the `.Types`.
      
      This ensures that we can make the internal record fields private, and
      offer accessors for things like `terminateDispatcher`. This preserve
      information hiding and allows us to change the internal way of
      terminating a dispatcher (for example switching away from normal
      `forkIO` in favour of `async` & co) while not breaking client's code.
      7c0d6ba0