How about use default type for syscall setsockopt
Hi all,
I don't know why we use unsigned int/long for all sockopt parameters. But how about use the default type for setsockopt. Then we can set optval for some special options such as SO_LIGNER, SO_SNDTIMEO...
include/net.h +4 -4
@@ -29,10 +29,10 @@ struct socket_triplet { };struct sockopt { -unsigned int level; -unsigned long optname; -unsigned long optval; -unsigned long optlen; +int level; +int optname; +const void *optval; +socklen_t optlen; };
Signature · 2 lines
Thanks & Best Regards Hangbin Liu <[email protected]>