Revision 4136911a dumbstreamer.c

View differences:

dumbstreamer.c
64 64
  struct nodeID *myID;
65 65
  char *my_addr = iface_addr(my_iface);
66 66

  
67
  myID = create_socket(my_addr, port);
68
  if (myID == NULL || getFD(myID) == -1) {
67
  myID = net_helper_init(my_addr, port);
68
  if (myID == NULL) {
69 69
    fprintf(stderr, "Error creating my socket (%s:%d)!\n", my_addr, port);
70 70
    free(my_addr);
71

  
71 72
    return NULL;
72 73
  }
73 74
  free(my_addr);
......
90 91
  if (srv_port != 0) {
91 92
    struct nodeID *srv;
92 93

  
93
    srv = create_socket(srv_ip, srv_port);
94
    srv = create_node(srv_ip, srv_port);
94 95
    if (srv == NULL) {
95 96
      fprintf(stderr, "Cannot resolve remote address %s:%d\n", srv_ip, srv_port);
96 97

  

Also available in: Unified diff