blob: 7aa9adc7fea7f0a0183c8e5e704e05c6a6c6778d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
$NetBSD: patch-aa,v 1.2 2001/09/22 16:22:30 tron Exp $
--- src/main.c.orig Sun May 27 05:26:22 2001
+++ src/main.c Sat Sep 22 18:18:32 2001
@@ -2,7 +2,9 @@
#include "gnutella.h"
#include <signal.h>
+#ifndef __NetBSD__
#include <mcheck.h>
+#endif
#include "interface.h"
#include "support.h"
@@ -274,13 +276,19 @@
/* Auto-connect to the network. */
if(up_connections && !stop_host_get) {
+ gint i;
+ const gchar *hosts[] = { "connect1.gnutellanet.com" , "connect2.gnutellanet.com" , "connect3.gnutellanet.com" , "connect4.gnutellanet.com" , NULL };
guint32 autoConnectIp = 0;
- autoConnectIp = host_to_ip("gnutellahosts.com");
- if (autoConnectIp != 0)
- {
- node_add(NULL, autoConnectIp, 6346);
- }
+ i = 0;
+ while (hosts[i] != NULL)
+ {
+ autoConnectIp = host_to_ip(hosts[i++]);
+ if (autoConnectIp != 0)
+ {
+ node_add(NULL, autoConnectIp, 6346);
+ }
+ }
}
|