chouxiaoya8100 发表于 2016-05-22 10:54 static/image/common/back.gif
回复 8# drangon
回复 11# drangon
父子进程都在监听的话,那么谁accept呢?
还有为什么会这么奇葩的技术存在?
复用是指SO_REUSEADDR/SO_REUSEPORT么?
stackoverflow上有个很经典的答案,http://stackoverflow.com/questions/14388706/socket-options-so-reuseaddr-and-so-reuseport-how-do-they-differ-do-they-mean-t 文件和进程是两个不同维度的东西,N个进程在等待一个fd ready的情况很常见啊,例如父子进程都从stdin读的情况……(当然实际不会有人这么做) 端口复用不是楼主那个意思
页:
1
[2]