adamdruppe / arsd

This is a collection of modules that I've released over the years. Most of them stand alone, or have just one or two dependencies in here, so you don't have to download this whole repo.
http://arsd-official.dpldocs.info/arsd.html
530 stars 125 forks source link

Use the alias socklen_t for portability #395

Closed Inkrementator closed 10 months ago

Inkrementator commented 10 months ago

cgi.d currently manually casts socklen_t to int on android. Currently, the [current commit in druntime] (https://github.com/dlang/dmd/blob/1188adc84ff1777f4a0153a8a5d7729ab5866dce/druntime/src/core/sys/posix/sys/socket.d) aliases socklen_t as uint, I can't find an exception for android or ARM.

To stay more robust to further changes in the druntime core library, I suggest just using socklen_t directly. I tested this on android 13 (termux) and linux.

adamdruppe commented 10 months ago

oh i think that wasn't present in some old version of the druntime but if it works now lets do it.