该函数是绑定Socket, 而在C++11中增加了std::bind(_Fp &&__f, _BoundArgs &&__bound_args...) 函数, 可以用该函数绑定函数指针, 当在C++类中添加了using namespace std;之后,如果你想调用socket.h中的bind方法则会出现问题, 使得bind函数调用不是你想要的行为。解决方案是在使用socket.h的bind函数的类中不要使用using namespace std
还可以这样 ::bind 调用 socket函数, 这样就不会调用std里的了
原文:https://blog.csdn.net/dstangrui/article/details/53540265