Samuli
Samuli
Currently `bqws_pt_connect()` blocks on platforms with POSIX sockets, with some refactoring connecting could be made non-blocking. This can be done transparently as the WebSocket API already has a `CONNECTING` state....
Don't attempt to receive a new message if the memory budget doesn't allow for it.. Add a function bqws_try_allocate_msg() that return NULL if there's no budget to allocate a message....
Increase the default limits so users don't hit them accidentally. Shuold probably aim for 10-100MB max memory usage. Also make sure max memory usage is around 2-5x max received message...
The WebSocket specification requires text messages to be validated as UTF-8. Should probably do some unrolling or SSE and NEON to skip through ASCII data as that's probably the most...
Namespace internal names like `ws_*` `hs_` under `bqws_` for better unity build experience..
Rewrite example code to make the samples clearer. It's probably not necessary to include too many features in one example..
There's already `#if defined(BQWS_USE_SSE)` in `mask_apply()`. We should define `BQWS_USE_NEON` where applicable and use NEON intrinsics to do the masking if possible. Defines to check: - `_MSC_VER` branch: `_M_ARM` or...
With one platform-specific atomic primitive `ws->alloc.memory_used` could be made atomic and a lot of mutexes could be avoided. This might cause over-committing the used memory for a moment but I...
When using CFStream the address is cached after being queried once. Currently there's one non-synced boolean which is pretty sketchy, should do it with acquire/release atomics. A mutex is probably...