add bind and remove segfault