Revision 0f23522a dumbstreamer.c

View differences:

dumbstreamer.c
18 18
static const char *my_addr = "127.0.0.1";
19 19
static int port = 6666;
20 20
static int srv_port;
21
static const char *srv_ip;
21
static const char *srv_ip = "";
22 22
static int period = 500;
23 23
static int chunks_per_second = 4;
24 24

  
......
77 77
    struct nodeID *srv;
78 78

  
79 79
    srv = create_socket(srv_ip, srv_port);
80
    if (srv == NULL) {
81
      fprintf(stderr, "Cannot resolve remote address %s:%d\n", srv_ip, srv_port);
82

  
83
      return -1;
84
    }
80 85
    topAddNeighbour(srv);
81 86

  
82 87
    loop(my_sock, 1000000 / chunks_per_second);

Also available in: Unified diff