[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r4944 - in GNUnet/src: applications/advertising application
From: |
gnunet |
Subject: |
[GNUnet-SVN] r4944 - in GNUnet/src: applications/advertising applications/datastore applications/dht/module applications/dht/tools applications/dstore applications/fs applications/fs/ecrs applications/fs/fsui applications/fs/lib applications/fs/module applications/fs/namespace applications/fs/tools applications/fs/uritrack applications/gap applications/identity applications/pingpong applications/session applications/sqstore_mysql applications/sqstore_sqlite applications/stats applications/tbench applications/testing applications/topology_f2f applications/traffic applications/transport include server setup/gtk setup/lib setup/ncurses transports transports/upnp util/boot util/containers util/cron util/crypto util/disk util/error util/network util/network_client util/os |
Date: |
Fri, 8 Jun 2007 00:18:59 -0600 (MDT) |
Author: grothoff
Date: 2007-06-08 00:18:58 -0600 (Fri, 08 Jun 2007)
New Revision: 4944
Modified:
GNUnet/src/applications/advertising/advertising.c
GNUnet/src/applications/advertising/advertising_test.c
GNUnet/src/applications/datastore/datastore.c
GNUnet/src/applications/dht/module/cs.c
GNUnet/src/applications/dht/module/routing.c
GNUnet/src/applications/dht/module/service.c
GNUnet/src/applications/dht/module/table.c
GNUnet/src/applications/dht/tools/dht-query.c
GNUnet/src/applications/dht/tools/dht_api.c
GNUnet/src/applications/dht/tools/dhttest.c
GNUnet/src/applications/dht/tools/dhttest2.c
GNUnet/src/applications/dstore/dstore.c
GNUnet/src/applications/fs/ecrs/bincoder.c
GNUnet/src/applications/fs/ecrs/directory.c
GNUnet/src/applications/fs/ecrs/directorytest.c
GNUnet/src/applications/fs/ecrs/download.c
GNUnet/src/applications/fs/ecrs/ecrs.h
GNUnet/src/applications/fs/ecrs/keyspace.c
GNUnet/src/applications/fs/ecrs/metatest.c
GNUnet/src/applications/fs/ecrs/namespace.c
GNUnet/src/applications/fs/ecrs/upload.c
GNUnet/src/applications/fs/ecrs/uri.c
GNUnet/src/applications/fs/ecrs/uritest.c
GNUnet/src/applications/fs/ecrs_core_test.c
GNUnet/src/applications/fs/fsui/download.c
GNUnet/src/applications/fs/fsui/fsuitest.c
GNUnet/src/applications/fs/fsui/upload.c
GNUnet/src/applications/fs/lib/fslib.c
GNUnet/src/applications/fs/module/dht_push.c
GNUnet/src/applications/fs/module/fs.c
GNUnet/src/applications/fs/module/querymanager.c
GNUnet/src/applications/fs/namespace/namespace_info.c
GNUnet/src/applications/fs/tools/gnunet-download.c
GNUnet/src/applications/fs/tools/gnunet-insert.c
GNUnet/src/applications/fs/uritrack/file_info.c
GNUnet/src/applications/fs/uritrack/uri_info.c
GNUnet/src/applications/gap/gap.c
GNUnet/src/applications/gap/gaptest2.c
GNUnet/src/applications/gap/gaptest3.c
GNUnet/src/applications/identity/clientapi.c
GNUnet/src/applications/identity/hostkey.c
GNUnet/src/applications/identity/identity.c
GNUnet/src/applications/identity/identity.h
GNUnet/src/applications/pingpong/pingpong.c
GNUnet/src/applications/session/connect.c
GNUnet/src/applications/session/sessiontest.c
GNUnet/src/applications/sqstore_mysql/mysql.c
GNUnet/src/applications/sqstore_sqlite/sqlite.c
GNUnet/src/applications/stats/clientapi.c
GNUnet/src/applications/tbench/tbenchtest_udp.c
GNUnet/src/applications/testing/testing.c
GNUnet/src/applications/topology_f2f/topology.c
GNUnet/src/applications/traffic/traffic.c
GNUnet/src/applications/transport/transport.c
GNUnet/src/include/gnunet_core.h
GNUnet/src/include/gnunet_dht_lib.h
GNUnet/src/include/gnunet_ecrs_lib.h
GNUnet/src/include/gnunet_fs_lib.h
GNUnet/src/include/gnunet_identity_lib.h
GNUnet/src/include/gnunet_peerinfo_lib.h
GNUnet/src/include/gnunet_setup_lib.h
GNUnet/src/include/gnunet_sqstore_service.h
GNUnet/src/include/gnunet_testing_lib.h
GNUnet/src/include/gnunet_transport.h
GNUnet/src/include/gnunet_transport_service.h
GNUnet/src/include/gnunet_uritrack_lib.h
GNUnet/src/include/gnunet_util_network.h
GNUnet/src/server/connection.c
GNUnet/src/server/gnunet-peer-info.c
GNUnet/src/server/gnunet-transport-check.c
GNUnet/src/server/gnunet-update.c
GNUnet/src/server/gnunetd.c
GNUnet/src/server/startup.c
GNUnet/src/server/version.c
GNUnet/src/setup/gtk/gconf.c
GNUnet/src/setup/lib/gns.c
GNUnet/src/setup/lib/tree.c
GNUnet/src/setup/ncurses/mconf.c
GNUnet/src/transports/http.c
GNUnet/src/transports/ip.c
GNUnet/src/transports/ip6.c
GNUnet/src/transports/tcp.c
GNUnet/src/transports/tcp6.c
GNUnet/src/transports/tcp_helper.c
GNUnet/src/transports/udp.c
GNUnet/src/transports/udp6.c
GNUnet/src/transports/upnp/error.c
GNUnet/src/transports/upnp/error.h
GNUnet/src/transports/upnp/init.c
GNUnet/src/transports/upnp/upnp.c
GNUnet/src/transports/upnp/upnptest.c
GNUnet/src/transports/upnp/util.c
GNUnet/src/transports/upnp/xmlnode.c
GNUnet/src/transports/upnp/xmlnode.h
GNUnet/src/util/boot/startup.c
GNUnet/src/util/containers/hashtabletest.c
GNUnet/src/util/cron/cron.c
GNUnet/src/util/crypto/hashingtest.c
GNUnet/src/util/crypto/hashperf.c
GNUnet/src/util/crypto/locking_gcrypt.c
GNUnet/src/util/disk/storage.c
GNUnet/src/util/error/error.c
GNUnet/src/util/network/ip.c
GNUnet/src/util/network/select.c
GNUnet/src/util/network/selecttest.c
GNUnet/src/util/network_client/tcpio.c
GNUnet/src/util/os/console.c
GNUnet/src/util/os/cpustatus.c
GNUnet/src/util/os/daemon.c
GNUnet/src/util/os/osconfig.c
GNUnet/src/util/os/semaphore.c
GNUnet/src/util/os/semaphoretest.c
GNUnet/src/util/os/statuscalls.c
Log:
removing whitespace
Modified: GNUnet/src/applications/advertising/advertising.c
===================================================================
--- GNUnet/src/applications/advertising/advertising.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/advertising/advertising.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -48,9 +48,9 @@
/**
* From time to time, forward one hello from one peer to
- * a random other peer.
+ * a random other peer.
*/
-#define HELLO_FORWARD_FREQUENCY (45 * cronSECONDS)
+#define HELLO_FORWARD_FREQUENCY (45 * cronSECONDS)
/**
* Meanings of the bits in activeCronJobs (ACJ).
@@ -362,13 +362,13 @@
if (mtu > ntohs(ping->size)) {
helloEnd = transport->getAdvertisedhellos(mtu - ntohs(ping->size),
buffer);
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
mtu - ntohs(ping->size) >= helloEnd);
} else {
helloEnd = -2;
}
if (helloEnd <= 0) {
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_WARNING | GE_BULK | GE_USER,
_("Failed to create an advertisement for this peer. Will not send
PING.\n"));
FREE(buffer);
@@ -389,7 +389,7 @@
(SYSERR == coreAPI->sendPlaintext(tsession,
buffer,
helloEnd)) ) {
-
+
if (stats != NULL)
stats->change(stat_hello_send_error, 1);
res = SYSERR;
@@ -435,7 +435,7 @@
GE_DEBUG | GE_REQUEST | GE_USER,
hash2enc(&hi->hashPubKey,
&other));
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Entering `%s' with target `%s'.\n",
__FUNCTION__,
@@ -499,7 +499,7 @@
P2P_hello_MESSAGE_size(sd->m));
transport->disconnect(tsession);
#if DEBUG_ADVERTISING
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Exit from %s.\n",
__FUNCTION__);
@@ -590,8 +590,8 @@
if (os_network_monitor_get_load(coreAPI->load_monitor,
Upload) > 100)
return; /* network load too high... */
- if (weak_randomi(fcc->prob) != 0)
- return; /* only forward with a certain chance */
+ if (weak_randomi(fcc->prob) != 0)
+ return; /* only forward with a certain chance */
if (equalsHashCode512(&peer->hashPubKey,
&fcc->msg->senderIdentity.hashPubKey))
return; /* do not bounce the hello of a peer back
@@ -640,7 +640,7 @@
#if DEBUG_ADVERTISING
EncName enc;
/* remove hellos that expired */
- IF_GELOG(ectx,
+ IF_GELOG(ectx,
GE_INFO | GE_REQUEST | GE_USER,
hash2enc(&peer->hashPubKey,
&enc));
@@ -680,7 +680,7 @@
static void
forwardhello(void * unused) {
int count;
-
+
if (os_cpu_get_load(coreAPI->ectx,
coreAPI->cfg) > 100)
return; /* CPU load too high... */
@@ -695,7 +695,7 @@
count = identity->forEachHost(0,
NULL,
NULL);
- if (count > 0)
+ if (count > 0)
identity->forEachHost(0, /* ignore blacklisting */
&forwardhelloHelper,
&count);
@@ -853,7 +853,7 @@
= stats->create(gettext_noop("# plaintext PING messages sent"));
}
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
_("`%s' registering handler %d (plaintext and ciphertext)\n"),
"advertising",
@@ -865,8 +865,8 @@
&phelloHandler);
if (0 != GC_attach_change_listener(capi->cfg,
&configurationUpdateCallback,
- NULL))
- GE_BREAK(capi->ectx, 0);
+ NULL))
+ GE_BREAK(capi->ectx, 0);
startBootstrap(capi);
GE_ASSERT(capi->ectx,
0 == GC_set_configuration_value_string(capi->cfg,
Modified: GNUnet/src/applications/advertising/advertising_test.c
===================================================================
--- GNUnet/src/applications/advertising/advertising_test.c 2007-06-08
06:18:08 UTC (rev 4943)
+++ GNUnet/src/applications/advertising/advertising_test.c 2007-06-08
06:18:58 UTC (rev 4944)
@@ -71,7 +71,7 @@
int found;
char buf[128];
int min;
-
+
ectx = NULL;
cfg = GC_create_C_impl();
if (-1 == GC_parse_configuration(cfg,
@@ -99,7 +99,7 @@
i,
(i+1) % NUM_PEERS);
GC_free(cfg);
- return -1;
+ return -1;
}
}
PTHREAD_SLEEP(15 * cronSECONDS);
@@ -133,7 +133,7 @@
}
fprintf(stderr,
"Have %d connections total in round %d, minimum number was %d\n",
- found,
+ found,
k,
min);
if (k < NUM_ROUNDS - 1)
Modified: GNUnet/src/applications/datastore/datastore.c
===================================================================
--- GNUnet/src/applications/datastore/datastore.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/datastore/datastore.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -263,7 +263,7 @@
GE_LOG(coreAPI->ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Migration: available %llu (need %u), min priority %u have %u\n",
- available,
+ available,
ntohl(value->size),
minPriority,
ntohl(value->prio));
@@ -495,7 +495,7 @@
initFilters(uapi->ectx,
uapi->cfg);
sq = uapi->requestService("sqstore");
- sq->get(NULL,
+ sq->get(NULL,
ANY_BLOCK,
&filterAddAll,
NULL);
Modified: GNUnet/src/applications/dht/module/cs.c
===================================================================
--- GNUnet/src/applications/dht/module/cs.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/dht/module/cs.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -77,7 +77,7 @@
req = (const CS_dht_request_put_MESSAGE*) message;
size = ntohs(req->header.size)
- sizeof(CS_dht_request_put_MESSAGE);
- GE_ASSERT(NULL,
+ GE_ASSERT(NULL,
size < MAX_BUFFER_SIZE);
#if DEBUG_CS
GE_LOG(coreAPI->ectx,
@@ -114,7 +114,7 @@
msg->header.size = htons(n);
msg->header.type = htons(CS_PROTO_dht_REQUEST_PUT);
msg->expire = 0; /* unknown */
- msg->key = *key;
+ msg->key = *key;
memcpy(&msg[1],
&value[1],
ntohl(value->size) - sizeof(DataContainer));
@@ -211,7 +211,7 @@
DHT_CLIENT_GET_RECORD * cgr;
MUTEX_LOCK(lock);
for (i=0;i<getRecordsSize;i++) {
- cgr = getRecords[i];
+ cgr = getRecords[i];
if (cgr->client == client) {
gr = cgr->get_record;
getRecords[i] = getRecords[getRecordsSize-1];
@@ -279,7 +279,7 @@
if (OK != coreAPI->unregisterClientExitHandler(&csClientExit))
status = SYSERR;
- while (getRecordsSize > 0)
+ while (getRecordsSize > 0)
get_timeout(getRecords[0]);
coreAPI->releaseService(dhtAPI);
dhtAPI = NULL;
Modified: GNUnet/src/applications/dht/module/routing.c
===================================================================
--- GNUnet/src/applications/dht/module/routing.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/dht/module/routing.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -304,7 +304,7 @@
pos = pos->next;
}
}
- MUTEX_UNLOCK(lock);
+ MUTEX_UNLOCK(lock);
#if DEBUG_ROUTING
GE_LOG(coreAPI->ectx,
GE_DEBUG | GE_REQUEST | GE_DEVELOPER,
@@ -346,7 +346,7 @@
sizeof(HashCode512))) &&
(records[i]->get->type == get->type) &&
(records[i]->expires > now - MAX_TTL) ) {
- /* do not route, same request already (recently)
+ /* do not route, same request already (recently)
active (possibly from other initiator) */
/* FIXME: support sending replies back to
multiple peers!? */
@@ -359,7 +359,7 @@
} else if (records[i]->expires < expire) {
expire = records[i]->expires;
rt_pos = i;
- }
+ }
}
if (rt_pos == rt_size) {
/* do not route, expiration time too high */
@@ -401,7 +401,7 @@
GE_DEBUG | GE_REQUEST | GE_DEVELOPER,
"Tracking request in slot %u\n",
rt_pos);
-#endif
+#endif
rt_pos = (rt_pos + 1) % rt_size;
MUTEX_UNLOCK(lock);
if (stats != NULL)
@@ -523,7 +523,7 @@
stats->change(stat_put_requests_received, 1);
put = (const DHT_PUT_MESSAGE*) msg;
#if DEBUG_ROUTING
- hash2enc(&put->key,
+ hash2enc(&put->key,
&enc);
GE_LOG(coreAPI->ectx,
GE_DEBUG | GE_REQUEST | GE_DEVELOPER,
@@ -573,7 +573,7 @@
ntohs(put->header.size) - sizeof(DHT_PUT_MESSAGE),
&put[1]);
#endif
- }
+ }
return OK;
}
@@ -627,7 +627,7 @@
if (OK == addRoute(NULL,
handler,
cls,
- &get))
+ &get))
handleGet(NULL,
&get.header);
}
@@ -718,7 +718,7 @@
* @param padding maximum number of bytes available
* @return number of bytes added at position
*/
-static unsigned int
+static unsigned int
extra_get_callback(const PeerIdentity * receiver,
void * position,
unsigned int padding) {
@@ -733,7 +733,7 @@
*/
int init_dht_routing(CoreAPIForApplication * capi) {
unsigned long long rts;
-
+
coreAPI = capi;
rts = 65536;
GC_get_configuration_value_number(coreAPI->cfg,
Modified: GNUnet/src/applications/dht/module/service.c
===================================================================
--- GNUnet/src/applications/dht/module/service.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/dht/module/service.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -40,7 +40,7 @@
typedef struct DHT_GET_RECORD {
/**
* Key that we are looking for.
- */
+ */
HashCode512 key;
/**
@@ -161,7 +161,7 @@
dht_get_stop(&record->key,
record->type,
&client_result_converter,
- record);
+ record);
FREE(record);
return OK;
}
@@ -173,7 +173,7 @@
* @param capi the core API
* @return NULL on errors, DHT_API otherwise
*/
-DHT_ServiceAPI *
+DHT_ServiceAPI *
provide_module_dht(CoreAPIForApplication * capi) {
static DHT_ServiceAPI api;
Modified: GNUnet/src/applications/dht/module/table.c
===================================================================
--- GNUnet/src/applications/dht/module/table.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/dht/module/table.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -40,7 +40,7 @@
* code tries best-match routing among entries in table
* + service.c: provide DHT services to rest of GNUnet process
* (i.e. register datastore with shared data, get/put operations)
- * + cs.c: services to out-of-process DHT clients (via dht-lib)
+ * + cs.c: services to out-of-process DHT clients (via dht-lib)
*/
#include "platform.h"
Modified: GNUnet/src/applications/dht/tools/dht-query.c
===================================================================
--- GNUnet/src/applications/dht/tools/dht-query.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/dht/tools/dht-query.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -87,7 +87,7 @@
GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Issuing '%s(%s)' command.\n",
- "get",
+ "get",
key);
#endif
if (timeout == 0)
@@ -142,7 +142,7 @@
} else {
printf(_("'%s(%s,%s)' failed.\n"),
"put",
- key,
+ key,
value);
}
FREE(dc);
Modified: GNUnet/src/applications/dht/tools/dht_api.c
===================================================================
--- GNUnet/src/applications/dht/tools/dht_api.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/dht/tools/dht_api.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -73,7 +73,7 @@
} GetInfo;
-static void *
+static void *
poll_thread(void * cls) {
GetInfo * info = cls;
MESSAGE_HEADER * reply;
@@ -82,11 +82,11 @@
unsigned short size;
while (info->aborted == NO) {
- if (connection_test_open(info->sock) == 0)
+ if (connection_test_open(info->sock) == 0)
break;
reply = NULL;
if (OK != connection_read(info->sock,
- &reply))
+ &reply))
break;
if ( (sizeof(CS_dht_request_put_MESSAGE) > ntohs(reply->size)) ||
(CS_PROTO_dht_REQUEST_PUT != ntohs(reply->type)) ) {
@@ -94,7 +94,7 @@
info->total = SYSERR;
break; /* invalid reply */
}
-
+
put = (CS_dht_request_put_MESSAGE*) reply;
/* re-use "expire" field of the reply (which is 0 anyway)
for the header of DataContainer (which fits) to avoid
@@ -106,7 +106,7 @@
(OK != info->processor(&put->key,
cont,
info->closure)) )
- info->aborted = YES;
+ info->aborted = YES;
info->total++;
FREE(reply);
}
@@ -227,7 +227,7 @@
#endif
sock = client_connection_create(ectx,
cfg);
- if (sock == NULL)
+ if (sock == NULL)
return SYSERR;
GE_ASSERT(NULL,
ntohl(value->size) >= sizeof(DataContainer));
Modified: GNUnet/src/applications/dht/tools/dhttest.c
===================================================================
--- GNUnet/src/applications/dht/tools/dhttest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/dht/tools/dhttest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -72,7 +72,7 @@
int k;
int found;
char buf[128];
-
+
ectx = NULL;
cfg = GC_create_C_impl();
if (-1 == GC_parse_configuration(cfg,
@@ -115,8 +115,8 @@
left);
sleep(5);
left--;
- if (left == 0)
- break;
+ if (left == 0)
+ break;
}
connection_destroy(sock);
if (ok == 0) {
@@ -191,7 +191,7 @@
/* end of actual test code */
fprintf(stderr,
"Found %u out of %u attempts in round %u.\n",
- found,
+ found,
NUM_PEERS * NUM_PEERS,
k);
}
Modified: GNUnet/src/applications/dht/tools/dhttest2.c
===================================================================
--- GNUnet/src/applications/dht/tools/dhttest2.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/dht/tools/dhttest2.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -69,7 +69,7 @@
struct GC_Configuration * cfg;
struct ClientServerConnection * sock;
int left;
-
+
ectx = NULL;
cfg = GC_create_C_impl();
if (-1 == GC_parse_configuration(cfg,
@@ -110,8 +110,8 @@
left);
sleep(5);
left--;
- if (left == 0)
- break;
+ if (left == 0)
+ break;
}
connection_destroy(sock);
if (ok == 0) {
@@ -141,8 +141,8 @@
left);
sleep(5);
left--;
- if (left == 0)
- break;
+ if (left == 0)
+ break;
}
connection_destroy(sock);
if (ok == 0) {
@@ -210,7 +210,7 @@
2 * cronSECONDS,
NULL,
NULL));
-
+
hash("key2", 4, &key);
printf("Peer2 gets key2.\n");
CHECK(1 == DHT_LIB_get(cfg,
Modified: GNUnet/src/applications/dstore/dstore.c
===================================================================
--- GNUnet/src/applications/dstore/dstore.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/dstore/dstore.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -133,8 +133,8 @@
}
CLOSE(fd);
if (SQLITE_OK != sqlite3_open(fn,
- &dbh))
- return SYSERR;
+ &dbh))
+ return SYSERR;
db_init(dbh);
sqlite3_close(dbh);
return OK;
@@ -154,8 +154,8 @@
sqlite3_stmt * stmt;
sqlite3_stmt * dstmt;
int err;
-
- if (payload * 10 <= quota * 9)
+
+ if (payload * 10 <= quota * 9)
return OK; /* we seem to be about 10% off */
#if DEBUG_DSTORE
GE_LOG(coreAPI->ectx,
@@ -172,13 +172,13 @@
(sq_prepare(dbh,
"DELETE FROM ds071 "
"WHERE size = ? AND type = ? AND puttime = ? AND expire = ?
AND key = ? AND value = ?",
- &dstmt) != SQLITE_OK) ) {
- GE_LOG(coreAPI->ectx,
+ &dstmt) != SQLITE_OK) ) {
+ GE_LOG(coreAPI->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
_("`%s' failed at %s:%d with error: %s\n"),
"sq_prepare",
__FILE__,
- __LINE__,
+ __LINE__,
sqlite3_errmsg(dbh));
GE_BREAK(NULL, 0);
if (dstmt != NULL)
@@ -208,7 +208,7 @@
memcpy(dcontent,
sqlite3_column_blob(stmt, 5),
dsize);
- sqlite3_reset(stmt);
+ sqlite3_reset(stmt);
sqlite3_bind_int(dstmt,
1,
dsize);
@@ -232,12 +232,12 @@
dsize,
SQLITE_TRANSIENT);
if ((err = sqlite3_step(dstmt)) != SQLITE_DONE) {
- GE_LOG(coreAPI->ectx,
+ GE_LOG(coreAPI->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
_("`%s' failed at %s:%d with error: %s\n"),
"sqlite3_step",
__FILE__,
- __LINE__,
+ __LINE__,
sqlite3_errmsg(dbh));
sqlite3_reset(dstmt);
GE_BREAK(NULL, 0); /* should delete but cannot!? */
@@ -252,15 +252,15 @@
payload,
quota);
#endif
- sqlite3_reset(dstmt);
+ sqlite3_reset(dstmt);
}
if (err != SQLITE_DONE) {
- GE_LOG(coreAPI->ectx,
+ GE_LOG(coreAPI->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
_("`%s' failed at %s:%d with error: %s\n"),
"sqlite3_step",
__FILE__,
- __LINE__,
+ __LINE__,
sqlite3_errmsg(dbh));
}
FREE(dcontent);
@@ -294,7 +294,7 @@
if (size > MAX_CONTENT_SIZE)
return SYSERR;
MUTEX_LOCK(lock);
- if ( (fn == NULL) ||
+ if ( (fn == NULL) ||
(SQLITE_OK != sqlite3_open(fn,
&dbh)) ) {
db_reset(dbh);
@@ -314,12 +314,12 @@
"UPDATE ds071 SET puttime=?, expire=? "
"WHERE key=? AND type=? AND size=? AND value=?",
&stmt) != SQLITE_OK) {
- GE_LOG(coreAPI->ectx,
+ GE_LOG(coreAPI->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
_("`%s' failed at %s:%d with error: %s\n"),
"sq_prepare",
__FILE__,
- __LINE__,
+ __LINE__,
sqlite3_errmsg(dbh));
sqlite3_close(dbh);
MUTEX_UNLOCK(lock);
@@ -367,12 +367,12 @@
"(size, type, puttime, expire, key, value) "
"VALUES (?, ?, ?, ?, ?, ?)",
&stmt) != SQLITE_OK) {
- GE_LOG(coreAPI->ectx,
+ GE_LOG(coreAPI->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
_("`%s' failed at %s:%d with error: %s\n"),
"sq_prepare",
__FILE__,
- __LINE__,
+ __LINE__,
sqlite3_errmsg(dbh));
sqlite3_close(dbh);
MUTEX_UNLOCK(lock);
@@ -441,7 +441,7 @@
unsigned int cnt;
MUTEX_LOCK(lock);
- if ( (fn == NULL) ||
+ if ( (fn == NULL) ||
(SQLITE_OK != sqlite3_open(fn,
&dbh)) ) {
db_reset(dbh);
@@ -457,12 +457,12 @@
if (sq_prepare(dbh,
"SELECT size, value FROM ds071 WHERE key=? AND type=? AND
expire >= ?",
&stmt) != SQLITE_OK) {
- GE_LOG(coreAPI->ectx,
+ GE_LOG(coreAPI->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
_("`%s' failed at %s:%d with error: %s\n"),
"sq_prepare",
__FILE__,
- __LINE__,
+ __LINE__,
sqlite3_errmsg(dbh));
sqlite3_close(dbh);
MUTEX_UNLOCK(lock);
@@ -524,9 +524,9 @@
"a);
if (quota == 0) /* error */
quota = 1;
- quota *= 1024 * 1024;
+ quota *= 1024 * 1024;
stats = capi->requestService("stats");
- if (stats != NULL)
+ if (stats != NULL)
stat_dstore_size = stats->create(gettext_noop("# bytes in dstore"));
return &api;
}
Modified: GNUnet/src/applications/fs/ecrs/bincoder.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/bincoder.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/bincoder.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -49,7 +49,7 @@
*
* @return converted data
*/
-static char *
+static char *
bin2enc(const void * data,
size_t size) {
size_t len;
@@ -76,7 +76,7 @@
hbits -= 6;
}
}
- if (hbits > 0)
+ if (hbits > 0)
ret[len++] = encTable__[bits & 63];
return ret;
}
@@ -85,7 +85,7 @@
/**
* Convert string back to binary data.
*
- * @param input '\0'-terminated string
+ * @param input '\0'-terminated string
* @param data where to write binary data
* @param size how much data should be converted
* @return number of characters processed from input,
Modified: GNUnet/src/applications/fs/ecrs/directory.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/directory.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/directory.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -70,7 +70,7 @@
GNUNET_DIRECTORY_MAGIC,
8)) ) {
memcpy(&mdSize,
- &data[8],
+ &data[8],
sizeof(unsigned int));
mdSize = ntohl(mdSize);
if (mdSize > len - 8 - sizeof(unsigned int) )
@@ -104,7 +104,7 @@
while ( (epos < len) &&
(data[epos] != '\0') )
epos++;
- if (epos >= len)
+ if (epos >= len)
return SYSERR; /* malformed - or partial download */
fi.uri = ECRS_stringToUri(ectx,
@@ -144,7 +144,7 @@
if (spcb != NULL)
spcb(&fi,
NULL,
- NO,
+ NO,
spcbClosure);
ECRS_freeMetaData(fi.meta);
ECRS_freeUri(fi.uri);
@@ -157,15 +157,15 @@
* data, return the end position of that data
* after alignment to the BLOCK_ALIGN_SIZE.
*/
-static unsigned long long
+static unsigned long long
do_align(unsigned long long start_position,
unsigned long long end_position) {
unsigned long long align;
-
+
align = (end_position / BLOCK_ALIGN_SIZE) * BLOCK_ALIGN_SIZE;
if ( (start_position < align) &&
- (end_position > align) )
- return align + end_position - start_position;
+ (end_position > align) )
+ return align + end_position - start_position;
return end_position;
}
@@ -202,16 +202,16 @@
cend = cpos + sizes[cval];
if (cpos % BLOCK_ALIGN_SIZE == 0) {
/* prefer placing the largest blocks first */
- cbad = - (cend % BLOCK_ALIGN_SIZE);
+ cbad = - (cend % BLOCK_ALIGN_SIZE);
} else {
if (cpos / BLOCK_ALIGN_SIZE == cend / BLOCK_ALIGN_SIZE) {
/* Data fits into the same block! Prefer small left-overs! */
- cbad = BLOCK_ALIGN_SIZE - cend % BLOCK_ALIGN_SIZE;
+ cbad = BLOCK_ALIGN_SIZE - cend % BLOCK_ALIGN_SIZE;
} else {
- /* Would have to waste space to re-align, add big factor, this
+ /* Would have to waste space to re-align, add big factor, this
case is a real loss (proportional to space wasted)! */
cbad = BLOCK_ALIGN_SIZE * (BLOCK_ALIGN_SIZE - cpos %
BLOCK_ALIGN_SIZE);
- }
+ }
}
if (cbad < badness) {
best = j;
@@ -281,7 +281,7 @@
for (i=0;i<count;i++) {
perm[i] = i;
ucs[i] = ECRS_uriToString(fis[i].uri);
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
ucs[i] != NULL);
psize = ECRS_sizeofMetaData(fis[i].meta,
ECRS_SERIALIZE_FULL);
@@ -289,11 +289,11 @@
GE_BREAK(ectx, 0);
FREE(sizes);
FREE(perm);
- while (i>=0)
+ while (i>=0)
FREE(ucs[i--]);
FREE(ucs);
return SYSERR;
- }
+ }
sizes[i] = psize + sizeof(unsigned int) + strlen(ucs[i]) + 1;
}
/* permutate entries to minimize alignment cost */
Modified: GNUnet/src/applications/fs/ecrs/directorytest.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/directorytest.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/ecrs/directorytest.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -70,7 +70,7 @@
char uri[512];
char txt[128];
int ret = 0;
-
+
cls.max = i;
fis = MALLOC(sizeof(ECRS_FileInfo) * i);
for (p=0;p<i;p++) {
@@ -117,7 +117,7 @@
ECRS_freeMetaData(fis[p].meta);
ECRS_freeUri(fis[p].uri);
}
- FREE(fis);
+ FREE(fis);
ABORT();
}
cls.pos = 0;
@@ -128,7 +128,7 @@
&meta2,
&processor,
&cls)) {
- printf("expected %u\n", i);
+ printf("expected %u\n", i);
ret = 1;
goto END;
}
Modified: GNUnet/src/applications/fs/ecrs/download.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/download.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/download.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -428,7 +428,7 @@
* to abort the RM as soon as possible.
*/
int abortFlag;
-
+
/**
* Is the request manager being destroyed?
* (if so, accessing the request list is illegal!)
@@ -450,7 +450,7 @@
*
* @return NULL on error
*/
-static RequestManager *
+static RequestManager *
createRequestManager(struct GE_Context * ectx,
struct GC_Configuration * cfg) {
RequestManager * rm;
@@ -607,7 +607,7 @@
= 0;
entry->searchHandle
= NULL;
- MUTEX_LOCK(rm->lock);
+ MUTEX_LOCK(rm->lock);
if (rm->shutdown == NO) {
GE_ASSERT(rm->ectx,
rm->requestListSize > 0);
@@ -875,7 +875,7 @@
&hc);
if (equalsHashCode512(&hc,
&node->chk.key)) {
- updateProgress(node,
+ updateProgress(node,
data,
size);
if (node->level > 0)
@@ -982,7 +982,7 @@
/**
* We received a CHK reply for a block. Decrypt. Note
- * that the caller (fslib) has already aquired the
+ * that the caller (fslib) has already aquired the
* RM lock (we sometimes aquire it again in callees,
* mostly because our callees could be also be theoretically
* called from elsewhere).
@@ -1339,7 +1339,7 @@
/**
- * Download parts of a file. Note that this will store
+ * Download parts of a file. Note that this will store
* the blocks at the respective offset in the given file.
* Also, the download is still using the blocking of the
* underlying ECRS encoding. As a result, the download
@@ -1352,7 +1352,7 @@
* limit the download to exactly those bytes.
*
* @param uri the URI of the file (determines what to download)
- * @param filename where to store the file
+ * @param filename where to store the file
* @param no_temporaries set to YES to disallow generation of temporary files
* @param start starting offset
* @param length length of the download (starting at offset)
@@ -1441,7 +1441,7 @@
return OK;
}
fid = uri->data.fi;
-
+
if ( (! ECRS_isFileUri(uri)) &&
(! ECRS_isLocationUri(uri))) {
GE_BREAK(ectx, 0);
Modified: GNUnet/src/applications/fs/ecrs/ecrs.h
===================================================================
--- GNUnet/src/applications/fs/ecrs/ecrs.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/ecrs.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -65,7 +65,7 @@
/**
* RSA signature over the FileIdentifier,
* hash of the peer and expiration time.
- * (everything until proto).
+ * (everything until proto).
*/
Signature contentSignature;
Modified: GNUnet/src/applications/fs/ecrs/keyspace.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/keyspace.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/keyspace.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -234,7 +234,7 @@
pk = makeKblockKey(&key);
getPublicKey(pk,
&kb->keyspace);
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
OK == sign(pk,
mdsize + strlen(dstURI) + 1,
&kb[1],
Modified: GNUnet/src/applications/fs/ecrs/metatest.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/metatest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/metatest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -41,12 +41,12 @@
m = ECRS_createMetaData();
if (OK != ECRS_addToMetaData(m,
EXTRACTOR_TITLE,
- "TestTitle"))
- ABORT(m);
+ "TestTitle"))
+ ABORT(m);
if (OK != ECRS_addToMetaData(m,
EXTRACTOR_AUTHOR,
- "TestTitle"))
- ABORT(m);
+ "TestTitle"))
+ ABORT(m);
if (OK == ECRS_addToMetaData(m,
EXTRACTOR_TITLE,
"TestTitle")) /* dup! */
@@ -109,7 +109,7 @@
val,
size);
FREE(val);
- if (m == NULL)
+ if (m == NULL)
ABORT(m);
val = MALLOC(256);
for (j=0;j<i;j++) {
Modified: GNUnet/src/applications/fs/ecrs/namespace.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/namespace.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/namespace.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -227,7 +227,7 @@
nb->rootEntry = *rootEntry;
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
OK == sign(hk,
mdsize + 3 * sizeof(HashCode512),
&nb->identifier,
@@ -522,7 +522,7 @@
- sizeof(PublicKey)
- sizeof(HashCode512));
/* FINALLY: sign & publish SBlock */
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
OK == sign(hk,
size
- sizeof(Signature)
Modified: GNUnet/src/applications/fs/ecrs/upload.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/upload.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/upload.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -429,7 +429,7 @@
iblocks[i] = NULL;
}
#if DEBUG_UPLOAD
- IF_GELOG(ectx,
+ IF_GELOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
hash2enc(&mchk.query,
&enc));
Modified: GNUnet/src/applications/fs/ecrs/uri.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/uri.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/uri.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -89,7 +89,7 @@
* Generate a keyword URI.
* @return NULL on error (i.e. keywordCount == 0)
*/
-static char *
+static char *
createKeywordURI(char ** keywords,
unsigned int keywordCount) {
size_t n;
@@ -113,7 +113,7 @@
/**
* Generate a subspace URI.
*/
-static char *
+static char *
createSubspaceURI(const HashCode512 * namespace,
const HashCode512 * identifier) {
size_t n;
@@ -137,7 +137,7 @@
/**
* Generate a file URI.
*/
-static char *
+static char *
createFileURI(const FileIdentifier * fi) {
char * ret;
EncName keyhash;
@@ -167,7 +167,7 @@
/**
* Create a (string) location URI from a Location.
*/
-static char *
+static char *
createLocURI(const Location * loc) {
size_t n;
char * ret;
@@ -414,7 +414,7 @@
char * dup;
char * addr;
-
+
GE_ASSERT(ectx, uri != NULL);
addr = NULL;
slen = strlen(uri);
@@ -441,7 +441,7 @@
while ( (uri[npos] != '\0') &&
(uri[npos] != '.') )
npos++;
- if (dup[npos] == '\0')
+ if (dup[npos] == '\0')
goto ERR;
dup[npos++] = '\0';
if ( (OK != enc2hash(&dup[pos],
@@ -464,7 +464,7 @@
ret = enc2bin(&dup[npos],
&loc->contentSignature,
sizeof(Signature));
- if (ret == -1)
+ if (ret == -1)
goto ERR;
npos += ret;
if (dup[npos++] != '.')
@@ -475,11 +475,11 @@
goto ERR;
/* Finally: verify sigs! */
if (OK != verifySig(&loc->fi,
- sizeof(FileIdentifier) +
+ sizeof(FileIdentifier) +
sizeof(PeerIdentity) +
sizeof(TIME_T),
&loc->contentSignature,
- &loc->peer))
+ &loc->peer))
goto ERR;
FREE(dup);
return OK;
@@ -900,12 +900,12 @@
if (memcmp(&uri1->data.loc,
&uri2->data.loc,
sizeof(FileIdentifier) +
- sizeof(PublicKey) +
+ sizeof(PublicKey) +
sizeof(TIME_T) +
sizeof(unsigned short) +
sizeof(unsigned short)) != 0)
return NO;
- return YES;
+ return YES;
default:
return NO;
}
@@ -951,7 +951,7 @@
* @param proto transport protocol to reach the peer
* @param sas sender address size (for HELLO)
* @param address sas bytes of address information
- * @param signer function to call for obtaining
+ * @param signer function to call for obtaining
* RSA signatures for "sender".
* @return the location URI
*/
@@ -960,7 +960,7 @@
const PublicKey * sender,
TIME_T expirationTime,
ECRS_SignFunction signer,
- void * signer_cls) {
+ void * signer_cls) {
struct ECRS_URI * uri;
if (baseUri->type != chk)
@@ -972,7 +972,7 @@
uri->data.loc.peer = *sender;
uri->data.loc.expirationTime = expirationTime;
signer(signer_cls,
- sizeof(FileIdentifier) +
+ sizeof(FileIdentifier) +
sizeof(PeerIdentity) +
sizeof(TIME_T),
&uri->data.loc.fi,
Modified: GNUnet/src/applications/fs/ecrs/uritest.c
===================================================================
--- GNUnet/src/applications/fs/ecrs/uritest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs/uritest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -103,7 +103,7 @@
return 1;
}
ECRS_freeUri(uri2);
- ECRS_freeUri(baseURI);
+ ECRS_freeUri(baseURI);
uric = ECRS_uriToString(uri);
#if 0
/* not for the faint of heart: */
@@ -123,7 +123,7 @@
ECRS_freeUri(uri2);
return 1;
}
- ECRS_freeUri(uri2);
+ ECRS_freeUri(uri2);
ECRS_freeUri(uri);
return 0;
}
Modified: GNUnet/src/applications/fs/ecrs_core_test.c
===================================================================
--- GNUnet/src/applications/fs/ecrs_core_test.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/ecrs_core_test.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -36,17 +36,17 @@
HashCode512 query;
HashCode512 key;
unsigned int len;
-
+
len = sizeof(DBlock) + 42;
data = MALLOC(len);
memset(&data[1], rand(), len - sizeof(DBlock));
data->type = htonl(D_BLOCK);
CHECK(D_BLOCK == getTypeOfBlock(len,
- data),
+ data),
data);
fileBlockGetKey(data, len, &key);
fileBlockGetQuery(data, len, &query);
- CHECK(OK == fileBlockEncode(data,
+ CHECK(OK == fileBlockEncode(data,
len,
&query,
&value),
Modified: GNUnet/src/applications/fs/fsui/download.c
===================================================================
--- GNUnet/src/applications/fs/fsui/download.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/fsui/download.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -35,7 +35,7 @@
#define DEBUG_DTM NO
/**
- * Mark the given URI as found in a directory
+ * Mark the given URI as found in a directory
* in URITRACK.
*/
static int listURIfoundDirectory(const ECRS_FileInfo * fi,
@@ -50,7 +50,7 @@
dl->ctx->cfg,
fi->uri,
URITRACK_DIRECTORY_FOUND);
-
+
return OK;
}
Modified: GNUnet/src/applications/fs/fsui/fsuitest.c
===================================================================
--- GNUnet/src/applications/fs/fsui/fsuitest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/fsui/fsuitest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -222,7 +222,7 @@
if (GNUNET_SHUTDOWN_TEST() == YES)
break;
}
- if (lastEvent != FSUI_unindex_completed)
+ if (lastEvent != FSUI_unindex_completed)
FSUI_abortUnindex(ctx, unindex);
FSUI_stopUnindex(ctx, unindex);
Modified: GNUnet/src/applications/fs/fsui/upload.c
===================================================================
--- GNUnet/src/applications/fs/fsui/upload.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/fsui/upload.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -156,7 +156,7 @@
}
pos = children;
while (pos != NULL) {
- if (pos->uri != NULL)
+ if (pos->uri != NULL)
URITRACK_addState(ectx,
cfg,
pos->uri,
@@ -283,7 +283,7 @@
error);
FREE(error);
return NULL;
- }
+ }
} else {
filename = STRDUP(utc->filename);
}
@@ -306,7 +306,7 @@
if (ret != OK) {
if (utc->state == FSUI_ACTIVE) {
const char *err;
-
+
err = GE_memory_get(mem, 0);
signalError(utc,
err ? err : "");
@@ -363,10 +363,10 @@
/* generate location URI for non-anonymous download */
struct ClientServerConnection * sock;
P2P_hello_MESSAGE * hello;
-
+
sock = client_connection_create(utc->shared->ctx->ectx,
utc->shared->ctx->cfg);
-
+
if (OK == gnunet_identity_get_self(sock,
&hello)) {
loc = ECRS_uriFromLocation(utc->uri,
@@ -374,7 +374,7 @@
ntohl(hello->expirationTime),
(ECRS_SignFunction)
&gnunet_identity_sign_function,
sock);
-
+
FREE(hello);
} else {
/* may happen if no transports are available... */
@@ -382,11 +382,11 @@
}
connection_destroy(sock);
} else {
- /* no location URI, use standard URI
+ /* no location URI, use standard URI
(copied here to allow free later) */
loc = ECRS_dupUri(utc->uri);
}
- if (utc->shared->global_keywords != NULL)
+ if (utc->shared->global_keywords != NULL)
ECRS_addToKeyspace(ectx,
utc->shared->ctx->cfg,
utc->shared->global_keywords,
@@ -394,7 +394,7 @@
utc->shared->priority,
utc->shared->expiration,
loc,
- utc->meta);
+ utc->meta);
if (utc->keywords != NULL)
ECRS_addToKeyspace(ectx,
utc->shared->ctx->cfg,
@@ -416,7 +416,7 @@
utc->meta);
ECRS_freeUri(uri);
}
- ECRS_freeUri(loc);
+ ECRS_freeUri(loc);
loc = NULL;
while (OK == ECRS_delFromMetaData(utc->meta,
EXTRACTOR_SPLIT,
Modified: GNUnet/src/applications/fs/lib/fslib.c
===================================================================
--- GNUnet/src/applications/fs/lib/fslib.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/lib/fslib.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -301,7 +301,7 @@
handle->req->header.type = htons(CS_PROTO_gap_QUERY_STOP);
GE_ASSERT(NULL, ctx->sock != NULL);
if (OK != connection_write(ctx->sock,
- &handle->req->header)) {
+ &handle->req->header)) {
GE_LOG(ctx->ectx,
GE_WARNING | GE_REQUEST | GE_DEVELOPER,
"FSLIB: failed to request stop search with gnunetd\n");
@@ -406,12 +406,12 @@
ri->header.type = htons(CS_PROTO_gap_INIT_INDEX);
ri->reserved = htonl(0);
ri->fileId = *fileHc;
- memcpy(&ri[1],
- fn,
+ memcpy(&ri[1],
+ fn,
strlen(fn));
#if DEBUG_FSLIB
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Sending index initialization request to gnunetd\n");
#endif
Modified: GNUnet/src/applications/fs/module/dht_push.c
===================================================================
--- GNUnet/src/applications/fs/module/dht_push.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/module/dht_push.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -55,7 +55,7 @@
* Total number of entries with anonymity 0.
* Used to calculate how long we should wait
* between iterations.
- */
+ */
static int total;
static Stats_ServiceAPI * stats;
@@ -88,14 +88,14 @@
return OK;
}
-static void * push_thread(void * cls) {
+static void * push_thread(void * cls) {
while ( (dht != NULL) &&
(sqstore != NULL) ) {
if (total == 0)
total = 1;
- total = sqstore->iterateNonAnonymous(0,
+ total = sqstore->iterateNonAnonymous(0,
YES,
- &push_callback,
+ &push_callback,
NULL);
if ( (dht != NULL) &&
(total == 0) )
@@ -112,13 +112,13 @@
DHT_ServiceAPI * d) {
coreAPI = capi;
dht = d;
- sqstore = capi->requestService("sqstore");
+ sqstore = capi->requestService("sqstore");
if (sqstore == NULL) {
GE_BREAK(capi->ectx, 0);
return;
}
stats = capi->requestService("stats");
- if (stats != NULL)
+ if (stats != NULL)
stat_push_count
= stats->create(gettext_noop("# blocks pushed into DHT"));
thread = PTHREAD_CREATE(&push_thread,
Modified: GNUnet/src/applications/fs/module/fs.c
===================================================================
--- GNUnet/src/applications/fs/module/fs.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/fs/module/fs.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -194,7 +194,7 @@
if (stats != NULL)
stats->change(stat_valid_replies_received, 1);
if (ntohll(dv->expirationTime) < get_time()) {
- /* do not do anything with expired data
+ /* do not do anything with expired data
_except_ if it is pure content that one
of our clients has requested -- then we
should ignore expiration */
@@ -202,7 +202,7 @@
processResponse(query, dv);
else if (stats != NULL)
stats->change(stat_expired_replies_dropped, 1);
-
+
FREE(dv);
return NO;
}
@@ -1190,9 +1190,9 @@
capi->releaseService(traffic);
return SYSERR;
}
- dht = capi->requestService("dht");
- if (dht != NULL)
- init_dht_push(capi, dht);
+ dht = capi->requestService("dht");
+ if (dht != NULL)
+ init_dht_push(capi, dht);
ltgSignal = SEMAPHORE_CREATE(0);
localGetProcessor = PTHREAD_CREATE(&localGetter,
NULL,
Modified: GNUnet/src/applications/fs/module/querymanager.c
===================================================================
--- GNUnet/src/applications/fs/module/querymanager.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/module/querymanager.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -154,7 +154,7 @@
EncName enc;
#endif
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
ntohl(value->size) > sizeof(Datastore_Value));
if ( (ntohll(value->expirationTime) < get_time()) &&
(ntohl(value->type) != D_BLOCK) )
Modified: GNUnet/src/applications/fs/namespace/namespace_info.c
===================================================================
--- GNUnet/src/applications/fs/namespace/namespace_info.c 2007-06-08
06:18:08 UTC (rev 4943)
+++ GNUnet/src/applications/fs/namespace/namespace_info.c 2007-06-08
06:18:58 UTC (rev 4944)
@@ -253,7 +253,7 @@
/**
- * Delete a local namespace.
+ * Delete a local namespace.
*
* @return OK on success, SYSERR on error
*/
@@ -815,7 +815,7 @@
&nid,
&fi,
updateInterval,
- creationTime);
+ creationTime);
ECRS_freeUri(fi.uri);
if (lastId != NULL) {
old = getUpdateDataFilename(ectx,
@@ -1044,7 +1044,7 @@
NS_NamespaceIterator iterator,
void * closure) {
struct DiscoveryCallback * list;
-
+
list = MALLOC(sizeof(struct DiscoveryCallback));
list->callback = iterator;
list->closure = closure;
Modified: GNUnet/src/applications/fs/tools/gnunet-download.c
===================================================================
--- GNUnet/src/applications/fs/tools/gnunet-download.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/tools/gnunet-download.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -173,11 +173,11 @@
strcpy(fn, filename);
strcat(fn, "/");
strcat(fn, f);
- if (verbose > 1)
+ if (verbose > 1)
printf(_("Starting download `%s'\n"),
f);
FREE(f);
- meta = ECRS_createMetaData();
+ meta = ECRS_createMetaData();
FSUI_startDownload(ctx,
anonymity,
do_recursive,
@@ -185,13 +185,13 @@
meta,
fn,
NULL,
- NULL);
+ NULL);
ECRS_freeMetaData(meta);
FREE(fn);
return OK;
}
-
+
/**
* Main function to download files from GNUnet.
*
@@ -248,7 +248,7 @@
errorCode = -1;
goto quit;
}
- }
+ }
try_rename = NO;
if (filename == NULL) {
@@ -289,7 +289,7 @@
NULL);
start_time = get_time();
errorCode = 1;
- if (do_directory) {
+ if (do_directory) {
void * data;
struct stat sbuf;
int fd;
@@ -307,8 +307,8 @@
(-1 == (fd = disk_file_open(ectx,
efn,
O_LARGEFILE | O_RDONLY)) ) ||
- (MAP_FAILED == (data = MMAP(NULL,
- sbuf.st_size,
+ (MAP_FAILED == (data = MMAP(NULL,
+ sbuf.st_size,
PROT_READ,
MAP_SHARED,
fd,
@@ -324,7 +324,7 @@
FREE(efn);
goto quit;
}
- meta = ECRS_createMetaData();
+ meta = ECRS_createMetaData();
count = ECRS_listDirectory(ectx,
data,
sbuf.st_size,
@@ -343,7 +343,7 @@
else
printf(_("Did not find any files in directory `%s'\n"),
argv[i]);
- }
+ }
} else {
meta = ECRS_createMetaData();
dl = FSUI_startDownload(ctx,
Modified: GNUnet/src/applications/fs/tools/gnunet-insert.c
===================================================================
--- GNUnet/src/applications/fs/tools/gnunet-insert.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/tools/gnunet-insert.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -152,7 +152,7 @@
char * fullName;
struct stat buf;
EXTRACTOR_KeywordList * list;
-
+
fullName = MALLOC(strlen(dir) + strlen(fn) + 2);
strcpy(fullName, dir);
if (dir[strlen(dir)-1] != DIR_SEPARATOR)
@@ -187,7 +187,7 @@
FREE(fullName);
return OK;
}
-
+
/**
* Print progess message.
@@ -384,23 +384,23 @@
"EXTRACTORS",
"",
&ex);
- if (strlen(ex) > 0)
+ if (strlen(ex) > 0)
l = EXTRACTOR_loadConfigLibraries(l,
- ex);
+ ex);
FREE(ex);
dirname = string_expandFileName(ectx, filename);
GE_ASSERT(ectx, dirname != NULL);
while ( (strlen(dirname) > 0) &&
(dirname[strlen(dirname)-1] == DIR_SEPARATOR) )
- dirname[strlen(dirname)-1] = '\0';
+ dirname[strlen(dirname)-1] = '\0';
fname = dirname;
while (strstr(fname, DIR_SEPARATOR_STR) != NULL)
fname = strstr(fname, DIR_SEPARATOR_STR) + 1;
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
fname != dirname);
fname[-1] = '\0';
listKeywords(fname,
- dirname,
+ dirname,
l);
FREE(dirname);
EXTRACTOR_removeAll(l);
Modified: GNUnet/src/applications/fs/uritrack/file_info.c
===================================================================
--- GNUnet/src/applications/fs/uritrack/file_info.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/uritrack/file_info.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -38,7 +38,7 @@
#define STATE_NAME DIR_SEPARATOR_STR "data" DIR_SEPARATOR_STR "fs_uridb"
#define TRACK_OPTION "fs_uridb_status"
-static struct IPC_SEMAPHORE *
+static struct IPC_SEMAPHORE *
createIPC(struct GE_Context * ectx,
struct GC_Configuration * cfg) {
char * basename;
@@ -60,7 +60,7 @@
return sem;
}
-static char *
+static char *
getUriDbName(struct GE_Context * ectx,
struct GC_Configuration * cfg) {
char * nw;
Modified: GNUnet/src/applications/fs/uritrack/uri_info.c
===================================================================
--- GNUnet/src/applications/fs/uritrack/uri_info.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/fs/uritrack/uri_info.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -23,7 +23,7 @@
* @brief information about URIs
* @author Christian Grothoff
*
- * Note that the information is only accurate with "high
+ * Note that the information is only accurate with "high
* probability" but not at all guaranteed (this is done
* to bound disk size of the DB and to get high performance).
*/
@@ -33,7 +33,7 @@
#include "gnunet_uritrack_lib.h"
#include "platform.h"
-static char *
+static char *
getDBName(struct GC_Configuration * cfg) {
char * basename;
char * ipcName;
@@ -46,9 +46,9 @@
&basename);
n = strlen(basename) + 512;
ipcName = MALLOC(n);
- SNPRINTF(ipcName,
- n,
- "%s/uri_info.db",
+ SNPRINTF(ipcName,
+ n,
+ "%s/uri_info.db",
basename);
FREE(basename);
return ipcName;
@@ -90,16 +90,16 @@
off_t o;
s = ECRS_uriToString(uri);
- crc = crc32N(s, strlen(s));
+ crc = crc32N(s, strlen(s));
FREE(s);
s = getDBName(cfg);
size = getDBSize(cfg);
fd = disk_file_open(ectx,
- s,
+ s,
O_RDONLY);
FREE(s);
- if (fd == -1)
- return URITRACK_FRESH;
+ if (fd == -1)
+ return URITRACK_FRESH;
o = 2 * (crc % size);
if (o != lseek(fd, o, SEEK_SET)) {
GE_LOG_STRERROR_FILE(ectx,
@@ -111,7 +111,7 @@
}
if (2 != read(fd, io, 2))
return URITRACK_FRESH;
- if (io[0] == (unsigned char) crc)
+ if (io[0] == (unsigned char) crc)
return (enum URITRACK_STATE) io[1];
return URITRACK_FRESH;
}
@@ -131,11 +131,11 @@
off_t o;
s = ECRS_uriToString(uri);
- crc = crc32N(s, strlen(s));
+ crc = crc32N(s, strlen(s));
FREE(s);
s = getDBName(cfg);
size = getDBSize(cfg);
- fd = disk_file_open(ectx,
+ fd = disk_file_open(ectx,
s,
O_RDWR | O_CREAT,
S_IRUSR | S_IWUSR);
@@ -155,7 +155,7 @@
}
if (2 != read(fd, io, 2)) {
io[0] = crc;
- io[1] = URITRACK_FRESH;
+ io[1] = URITRACK_FRESH;
} else if (io[0] != (unsigned char) crc) {
io[0] = (unsigned char) crc;
io[1] = URITRACK_FRESH;
@@ -169,8 +169,8 @@
CLOSE(fd);
FREE(s);
return;
- }
- if (2 != write(fd, io, 2))
+ }
+ if (2 != write(fd, io, 2))
GE_LOG_STRERROR_FILE(ectx,
GE_WARNING | GE_USER | GE_ADMIN | GE_BULK,
"write",
Modified: GNUnet/src/applications/gap/gap.c
===================================================================
--- GNUnet/src/applications/gap/gap.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/applications/gap/gap.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -1,17 +1,17 @@
/*
This file is part of GNUnet
(C) 2001, 2002, 2003, 2004, 2005, 2006, 2007 Christian Grothoff (and other
contributing authors)
-
+
GNUnet is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
by the Free Software Foundation; either version 2, or (at your
option) any later version.
-
+
GNUnet is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
-
+
You should have received a copy of the GNU General Public License
along with GNUnet; see the file COPYING. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
@@ -543,7 +543,7 @@
void * cls) {
const QueryRecord * qr = cls;
PID_INDEX id;
-#if DEBUG_GAP
+#if DEBUG_GAP
EncName encq;
EncName encp;
#endif
@@ -678,7 +678,7 @@
memcpy(qr->msg,
msg,
ntohs(msg->header.size));
- if (noclear == NO)
+ if (noclear == NO)
memset(&qr->bitmap[0],
0,
BITMAP_SIZE);
@@ -719,7 +719,7 @@
}
}
}
- FREE(qr->rankings);
+ FREE(qr->rankings);
qr->rankings = NULL;
if (target != NULL) {
tpid = intern_pid(target);
@@ -1338,7 +1338,7 @@
#endif
if (stats != NULL)
- stats->change(stat_routing_successes,
+ stats->change(stat_routing_successes,
1);
now = get_time();
if (now < ite->ttl)
@@ -1473,8 +1473,8 @@
#endif
/* Load above hard limit? */
- if (loadTooHigh())
- return SYSERR;
+ if (loadTooHigh())
+ return SYSERR;
senderID = intern_pid(sender);
GE_ASSERT(ectx, (senderID != 0) || (sender == NULL) );
@@ -1707,7 +1707,7 @@
GE_BREAK(ectx, 0);
FREE(value);
return SYSERR; /* invalid */
- }
+ }
/* THIRD: compute content priority/value and
send remote reply (ITE processing) */
@@ -1976,7 +1976,7 @@
unsigned int size;
size = sizeof(P2P_gap_reply_MESSAGE) + ntohl(data->size) -
sizeof(DataContainer);
- if ( (size > padding) ||
+ if ( (size > padding) ||
(size >= MAX_BUFFER_SIZE) )
return 0;
reply = (P2P_gap_reply_MESSAGE*) position;
@@ -2025,7 +2025,7 @@
if (loadTooHigh()) {
#if DEBUG_GAP
if (sender != NULL) {
- IF_GELOG(ectx,
+ IF_GELOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
hash2enc(&sender->hashPubKey,
&enc));
Modified: GNUnet/src/applications/gap/gaptest2.c
===================================================================
--- GNUnet/src/applications/gap/gaptest2.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/gap/gaptest2.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -294,7 +294,7 @@
SNPRINTF(buf,
128,
"localhost:%u",
- 2077 + PEER_COUNT * 10);
+ 2077 + PEER_COUNT * 10);
GC_set_configuration_value_string(cfg,
ectx,
"NETWORK",
Modified: GNUnet/src/applications/gap/gaptest3.c
===================================================================
--- GNUnet/src/applications/gap/gaptest3.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/gap/gaptest3.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -93,11 +93,11 @@
NULL,
&testTerminate,
NULL,
- &uri);
+ &uri);
FREE(name);
- if (ret != SYSERR)
+ if (ret != SYSERR)
return uri;
- return NULL;
+ return NULL;
}
static int downloadFile(unsigned int size,
@@ -167,7 +167,7 @@
int i;
int good;
EncName enc;
-
+
good = 0;
for (i=0;i<goodPeerPos;i++)
if (0 == memcmp(&goodPeers[i],
@@ -176,8 +176,8 @@
good = 1;
hash2enc(&identity->hashPubKey,
&enc);
- if (good)
- printf("Good peer `%8s' has trust %u and bandwidth %u\n",
+ if (good)
+ printf("Good peer `%8s' has trust %u and bandwidth %u\n",
(const char*) &enc,
trust,
bpmFromPeer);
@@ -203,7 +203,7 @@
struct ClientServerConnection * sock;
cron_t start;
EncName enc;
-
+
ret = 0;
cfg = GC_create_C_impl();
if (-1 == GC_parse_configuration(cfg,
@@ -243,7 +243,7 @@
SNPRINTF(buf,
128,
"localhost:%u",
- 2087 + i * 10);
+ 2087 + i * 10);
GC_set_configuration_value_string(cfg,
ectx,
"NETWORK",
@@ -262,7 +262,7 @@
ECRS_freeUri(uri);
hash2enc(&hello->senderIdentity.hashPubKey,
&enc);
- printf("Uploading to peer `%8s'\n",
+ printf("Uploading to peer `%8s'\n",
(const char*)&enc);
uri = uploadFile(SIZE);
CHECK(NULL != uri);
Modified: GNUnet/src/applications/identity/clientapi.c
===================================================================
--- GNUnet/src/applications/identity/clientapi.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/identity/clientapi.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -56,7 +56,7 @@
GE_BREAK(NULL, 0);
FREE(msg);
return SYSERR;
- }
+ }
if (SYSERR == connection_write(sock,
&msg->header)) {
FREE(msg);
@@ -77,7 +77,7 @@
Signature * result) {
MESSAGE_HEADER * req;
CS_identity_signature_MESSAGE * reply;
-
+
req = MALLOC(sizeof(MESSAGE_HEADER) + size);
req->size = htons(sizeof(MESSAGE_HEADER) + size);
req->type = htons(CS_PROTO_identity_request_SIGN);
@@ -106,7 +106,7 @@
}
/**
- * Function to request one of the peer's identities
+ * Function to request one of the peer's identities
* (that is, external addresses).
* Except for the "sock" argument, all arguments are
* set by the function.
@@ -120,8 +120,8 @@
req.size = htons(sizeof(MESSAGE_HEADER));
req.type = htons(CS_PROTO_identity_request_HELLO);
if (SYSERR == connection_write(sock,
- &req))
- return SYSERR;
+ &req))
+ return SYSERR;
if (OK != connection_read(sock,
(MESSAGE_HEADER**)&reply)) {
connection_close_temporarily(sock);
@@ -146,7 +146,7 @@
*/
int gnunet_identity_request_connect(struct ClientServerConnection * sock,
const PeerIdentity * peer) {
-
+
CS_identity_connect_MESSAGE msg;
int result;
@@ -154,7 +154,7 @@
= htons(CS_PROTO_identity_CONNECT);
msg.header.size
= htons(sizeof(CS_identity_connect_MESSAGE));
- msg.other
+ msg.other
= *peer;
if (SYSERR == connection_write(sock,
&msg.header))
@@ -168,7 +168,7 @@
/**
* Request information about all known peers
*
- * @return SYSERR if iteration was aborted,
+ * @return SYSERR if iteration was aborted,
* otherwise number of peers known
*/
int gnunet_identity_request_peer_infos(struct ClientServerConnection * sock,
@@ -216,7 +216,7 @@
return SYSERR;
}
}
- FREE(reply);
+ FREE(reply);
}
return SYSERR;
}
Modified: GNUnet/src/applications/identity/hostkey.c
===================================================================
--- GNUnet/src/applications/identity/hostkey.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/identity/hostkey.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -139,7 +139,7 @@
hostkeyfile,
sizeof(unsigned short),
&len);
- }
+ }
encPrivateKey = NULL;
if (res == sizeof(unsigned short)) {
encPrivateKey = (PrivateKeyEncoded*) MALLOC(ntohs(len));
Modified: GNUnet/src/applications/identity/identity.c
===================================================================
--- GNUnet/src/applications/identity/identity.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/identity/identity.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -639,7 +639,7 @@
* @param result where to store the result
* @returns SYSERR on failure, OK on success
*/
-static P2P_hello_MESSAGE *
+static P2P_hello_MESSAGE *
identity2Hello(const PeerIdentity * hostId,
unsigned short protocol,
int tryTemporaryList) {
@@ -675,7 +675,7 @@
if (j == host->helloCount) {
/* not found */
MUTEX_UNLOCK(lock_);
- return NULL;
+ return NULL;
}
result = MALLOC(P2P_hello_MESSAGE_size(host->hellos[j]));
memcpy(result,
@@ -686,7 +686,7 @@
}
}
}
-
+
host = findHost(hostId);
if ( (host == NULL) ||
(host->protocolCount == 0) ) {
@@ -980,7 +980,7 @@
int ret;
ret = OK;
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
numberOfHosts_ <= sizeOfHosts_);
count = 0;
MUTEX_LOCK(lock_);
@@ -1103,7 +1103,7 @@
int hostFile;
fn = MALLOC(strlen(filename) + strlen(dirname) + 2);
- sprintf(fn,
+ sprintf(fn,
"%s%s%s",
dirname,
DIR_SEPARATOR_STR,
@@ -1173,7 +1173,7 @@
}
hello = MALLOC(ntohs(msg->header.size));
memcpy(hello,
- msg,
+ msg,
ntohs(msg->header.size));
hello->header.type = htons(p2p_PROTO_hello);
coreAPI->injectMessage(NULL,
@@ -1190,7 +1190,7 @@
/* transport types in order of preference
for location URIs (by best guess at what
people are most likely to actually run) */
- static unsigned short types[] = {
+ static unsigned short types[] = {
TCP_PROTOCOL_NUMBER,
UDP_PROTOCOL_NUMBER,
HTTP_PROTOCOL_NUMBER,
@@ -1214,7 +1214,7 @@
hello = NULL;
pos = 0;
while ( (hello == NULL) &&
- (types[pos] != 0) )
+ (types[pos] != 0) )
hello = tapi->createhello(types[pos++]);
coreAPI->releaseService(tapi);
if (hello == NULL)
@@ -1229,7 +1229,7 @@
static int identityRequestSignatureHandler(struct ClientHandle * sock,
const MESSAGE_HEADER * message) {
CS_identity_signature_MESSAGE reply;
-
+
if (ntohs(message->size) <= sizeof(MESSAGE_HEADER))
return SYSERR;
reply.header.size = htons(sizeof(CS_identity_signature_MESSAGE));
@@ -1254,7 +1254,7 @@
int ret;
unsigned int bpm;
cron_t last;
-
+
if (confirmed == NO)
return OK;
hello = identity2Hello(identity,
@@ -1291,7 +1291,7 @@
FREE(address);
ret = coreAPI->sendToClient(sock,
&reply->header);
- FREE(reply);
+ FREE(reply);
return ret;
}
@@ -1395,7 +1395,7 @@
&cronDiscardHosts,
0,
CRON_DISCARD_HOSTS_INTERVAL,
- NULL);
+ NULL);
coreAPI->registerClientHandler(CS_PROTO_identity_CONNECT,
&identityRequestConnectHandler);
coreAPI->registerClientHandler(CS_PROTO_identity_HELLO,
Modified: GNUnet/src/applications/identity/identity.h
===================================================================
--- GNUnet/src/applications/identity/identity.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/identity/identity.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -59,7 +59,7 @@
PeerIdentity peer;
cron_t last_message;
-
+
unsigned int bpm;
} CS_identity_peer_info_MESSAGE;
Modified: GNUnet/src/applications/pingpong/pingpong.c
===================================================================
--- GNUnet/src/applications/pingpong/pingpong.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/pingpong/pingpong.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -233,7 +233,7 @@
#if DEBUG_PINGPONG
EncName enc;
#endif
-
+
pmsg = (P2P_pingpong_MESSAGE *) msg;
if ( (ntohs(msg->size) != sizeof(P2P_pingpong_MESSAGE)) ||
(0 != memcmp(sender,
@@ -439,7 +439,7 @@
if (pmsg == NULL)
return SYSERR;
if (usePlaintext == YES) {
- if (OK != sendPlaintext(receiver,
+ if (OK != sendPlaintext(receiver,
(const P2P_pingpong_MESSAGE*) pmsg)) {
FREE(pmsg);
return SYSERR;
Modified: GNUnet/src/applications/session/connect.c
===================================================================
--- GNUnet/src/applications/session/connect.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/session/connect.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -327,11 +327,11 @@
(0 != memcmp(&hc,
&foreignHello->senderIdentity,
sizeof(PeerIdentity))) ) {
- GE_BREAK(NULL,
+ GE_BREAK(NULL,
0 == memcmp(&hc,
&foreignHello->senderIdentity,
sizeof(PeerIdentity)));
- GE_BREAK(NULL,
+ GE_BREAK(NULL,
0 == memcmp(&hc,
hostId,
sizeof(PeerIdentity)));
@@ -339,8 +339,8 @@
FREE(foreignHello);
return NULL;
}
-
+
size = sizeof(P2P_new_setkey_MESSAGE);
if (ping != NULL)
size += ntohs(ping->size);
@@ -436,7 +436,7 @@
PeerIdentity * sndr;
EncName enc;
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
receiver != NULL);
if ( (tsession != NULL) &&
(0 != memcmp(&tsession->peer,
@@ -452,7 +452,7 @@
&enc);
/* then try to connect on the transport level */
if ( (tsession == NULL) ||
- (transport->associate(tsession) == SYSERR) )
+ (transport->associate(tsession) == SYSERR) )
tsession = transport->connectFreely(receiver,
YES);
if (tsession == NULL) {
@@ -462,7 +462,7 @@
"Key exchange with `%s' failed: could not connect.\n",
&enc);
#endif
- return SYSERR; /* failed to connect */
+ return SYSERR; /* failed to connect */
}
/* create our ping */
@@ -509,7 +509,7 @@
/* create hello */
hello = transport->createhello(tsession->ttype);
- if (NULL == hello)
+ if (NULL == hello)
hello = transport->createhello(ANY_PROTOCOL_NUMBER);
if (NULL == hello) {
GE_LOG(ectx,
@@ -777,7 +777,7 @@
#endif
ping->type = htons(p2p_PROTO_PONG);
if (stats != NULL)
- stats->change(stat_pongSent, 1);
+ stats->change(stat_pongSent, 1);
coreAPI->unicast(sender,
ping,
EXTREME_PRIORITY,
@@ -794,7 +794,7 @@
#endif
ping->type = htons(p2p_PROTO_PONG);
if (stats != NULL)
- stats->change(stat_pongSent, 1);
+ stats->change(stat_pongSent, 1);
exchangeKey(sender,
tsession,
ping); /* ping is now pong */
Modified: GNUnet/src/applications/session/sessiontest.c
===================================================================
--- GNUnet/src/applications/session/sessiontest.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/session/sessiontest.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -72,7 +72,7 @@
}
#if START_PEERS
peers = gnunet_testing_start_daemons("tcp",
- "advertising stats",
+ "advertising stats",
"/tmp/gnunet-session-test",
2087,
10000,
Modified: GNUnet/src/applications/sqstore_mysql/mysql.c
===================================================================
--- GNUnet/src/applications/sqstore_mysql/mysql.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/sqstore_mysql/mysql.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -637,7 +637,7 @@
}
/**
- * Iterate over the items in the datastore that
+ * Iterate over the items in the datastore that
* have anonymity level 0.
*
* @param type entries of which type should be considered?
@@ -652,7 +652,7 @@
void * closure) {
char limit[512];
- if (on_demand == YES)
+ if (on_demand == YES)
SNPRINTF(limit,
512,
"SELECT SQL_NO_CACHE * FROM gn070"
@@ -1267,7 +1267,7 @@
dbh->ubind[3].length = &twenty;
dbh->ubind[4].buffer = (char*) &value[1];
dbh->ubind[4].length = &contentSize;
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
mysql_stmt_param_count(dbh->update) <= 5);
if (mysql_stmt_bind_param(dbh->update,
dbh->ubind)) {
Modified: GNUnet/src/applications/sqstore_sqlite/sqlite.c
===================================================================
--- GNUnet/src/applications/sqstore_sqlite/sqlite.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/sqstore_sqlite/sqlite.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -479,7 +479,7 @@
if (sq_prepare(dbh,
"INSERT INTO gn070(hash, anonLevel, type) VALUES (?, ?, ?)",
- &stmt) != SQLITE_OK)
+ &stmt) != SQLITE_OK)
return SYSERR;
sqlite3_bind_text(stmt,
1,
@@ -500,7 +500,7 @@
return SYSERR;
}
sqlite3_finalize(stmt);
-
+
return OK;
}
@@ -577,7 +577,7 @@
512 - strlen(scratch),
" AND type != %d AND type != %d",
RESERVED_BLOCK,
- ONDEMAND_BLOCK);
+ ONDEMAND_BLOCK);
} else {
SNPRINTF(&scratch[strlen(scratch)],
512 - strlen(scratch),
@@ -745,8 +745,8 @@
*
* @param type limit the iteration to entries of this
* type. 0 for all entries.
- * @param on_demand limit the iteration to entries
- * that not on-demand?
+ * @param on_demand limit the iteration to entries
+ * that not on-demand?
* @param iter the callback method
* @param closure argument to all callback calls
* @return the number of results, SYSERR if the
@@ -789,7 +789,7 @@
/**
* Call a method for each key in the database and
- * do so quickly in any order (can lock the
+ * do so quickly in any order (can lock the
* database until iteration is complete).
*
* @param callback the callback method
Modified: GNUnet/src/applications/stats/clientapi.c
===================================================================
--- GNUnet/src/applications/stats/clientapi.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/stats/clientapi.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -34,7 +34,7 @@
/**
* Return a descriptive name for a p2p message type
*/
-const char *
+const char *
STATS_p2pMessageName(unsigned short type) {
const char *name = NULL;
@@ -214,7 +214,7 @@
break;
case CS_PROTO_tbench_REPLY :
name = "CS_PROTO_tbench_REPLY";
- break;
+ break;
case CS_PROTO_tracekit_PROBE :
name = "CS_PROTO_tracekit_PROBE";
Modified: GNUnet/src/applications/tbench/tbenchtest_udp.c
===================================================================
--- GNUnet/src/applications/tbench/tbenchtest_udp.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/tbench/tbenchtest_udp.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -148,7 +148,7 @@
}
sock = client_connection_create(NULL,
cfg);
-
+
printf(_("Running benchmark...\n"));
/* 'slow' pass: wait for bandwidth negotiation! */
if (ret == 0)
@@ -161,7 +161,7 @@
ret = test(sock, 32768, 10, 10, 500 * cronMILLIS, 1, 10 * cronSECONDS);
connection_destroy(sock);
#if START_PEERS
- gnunet_testing_stop_daemons(peers);
+ gnunet_testing_stop_daemons(peers);
#endif
if (ok == 0)
ret = 1;
Modified: GNUnet/src/applications/testing/testing.c
===================================================================
--- GNUnet/src/applications/testing/testing.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/testing/testing.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -149,7 +149,7 @@
GC_free(cfg);
return SYSERR;
}
- CLOSE(ret);
+ CLOSE(ret);
if (0 != GC_write_configuration(cfg,
dpath)) {
fprintf(stderr,
@@ -158,7 +158,7 @@
FREE(dpath);
GC_free(cfg);
return SYSERR;
- }
+ }
GC_free(cfg);
cfg = GC_create_C_impl();
@@ -181,8 +181,8 @@
fprintf(stderr,
"Failed to start daemon!\n");
GC_free(cfg);
- return SYSERR;
- }
+ return SYSERR;
+ }
*pid = ret;
/* now get peer ID */
@@ -231,7 +231,7 @@
/**
* Establish a connection between two GNUnet daemons
* (both must run on this machine).
- *
+ *
* @param port1 client port of the first daemon
* @param port2 client port of the second daemon
* @return OK on success, SYSERR on failure
@@ -271,13 +271,13 @@
300 * cronSECONDS) ) &&
(OK == connection_wait_for_running(NULL,
cfg2,
- 300 * cronSECONDS) ) ) {
+ 300 * cronSECONDS) ) ) {
sock1 = client_connection_create(NULL,
cfg1);
sock2 = client_connection_create(NULL,
cfg2);
ret = - 10;
- fprintf(stderr,
+ fprintf(stderr,
_("Waiting for peers to connect"));
while ( (ret++ < -1) &&
(GNUNET_SHUTDOWN_TEST() == NO) ) {
@@ -309,7 +309,7 @@
}
fprintf(stderr, "%s\n", ret == OK ? "!" : "?");
connection_destroy(sock1);
- connection_destroy(sock2);
+ connection_destroy(sock2);
} else {
fprintf(stderr,
"Failed to establish connection with peers.\n");
@@ -341,7 +341,7 @@
*
* @return handle used to stop the daemons, NULL on error
*/
-struct DaemonContext *
+struct DaemonContext *
gnunet_testing_start_daemons(const char * transports,
const char * applications,
const char * gnunetd_home_prefix,
@@ -403,11 +403,11 @@
UNLINK(peers->configFile);
FREE(peers->configFile);
FREE(peers);
- peers = next;
+ peers = next;
}
return ret;
}
-
+
Modified: GNUnet/src/applications/topology_f2f/topology.c
===================================================================
--- GNUnet/src/applications/topology_f2f/topology.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/topology_f2f/topology.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -280,7 +280,7 @@
"Sending ping to `%s' to prevent connection timeout.\n",
(char*)&enc);
#endif
- if (OK != pingpong->ping(peer,
+ if (OK != pingpong->ping(peer,
¬ifyPONG,
hi,
NO,
Modified: GNUnet/src/applications/traffic/traffic.c
===================================================================
--- GNUnet/src/applications/traffic/traffic.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/applications/traffic/traffic.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -530,7 +530,7 @@
/**
* Initialize the traffic module.
*/
-Traffic_ServiceAPI *
+Traffic_ServiceAPI *
provide_module_traffic(CoreAPIForApplication * capi) {
static Traffic_ServiceAPI api;
#if KEEP_RECEIVE_STATS || KEEP_TRANSMITTED_STATS
@@ -538,7 +538,7 @@
#endif
coreAPI = capi;
-#if DEBUG
+#if DEBUG
GC_get_configuration_value_number(capi->cfg,
"NETWORK",
"PORT",
Modified: GNUnet/src/applications/transport/transport.c
===================================================================
--- GNUnet/src/applications/transport/transport.c 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/applications/transport/transport.c 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -129,7 +129,7 @@
/**
* Convert hello to string.
*/
-static char *
+static char *
helloToString(const P2P_hello_MESSAGE * hello,
int resolve_ip) {
unsigned short prot;
@@ -177,7 +177,7 @@
* if SYSERR is returned!
* @return OK on success, SYSERR on error
*/
-static TSession *
+static TSession *
transportConnect(const P2P_hello_MESSAGE * hello) {
unsigned short prot;
TSession * tsession;
@@ -198,7 +198,7 @@
return tsession;
}
-static TSession *
+static TSession *
transportConnectFreely(const PeerIdentity * peer,
int useTempList) {
int i;
@@ -218,12 +218,12 @@
hello = identity->identity2Hello(peer,
perm[i],
useTempList);
- if (hello == NULL)
+ if (hello == NULL)
continue;
hc++;
ret = transportConnect(hello);
FREE(hello);
- if (ret != NULL)
+ if (ret != NULL)
break;
}
FREE(perm);
@@ -570,11 +570,11 @@
static int testWouldTry(TSession * tsession,
unsigned int size,
int important) {
- if (tsession == NULL)
- return SYSERR;
+ if (tsession == NULL)
+ return SYSERR;
if ( (tsession->ttype >= tapis_count) ||
- (tapis[tsession->ttype] == NULL) )
- return SYSERR;
+ (tapis[tsession->ttype] == NULL) )
+ return SYSERR;
return tapis[tsession->ttype]->testWouldTry(tsession,
size,
important);
Modified: GNUnet/src/include/gnunet_core.h
===================================================================
--- GNUnet/src/include/gnunet_core.h 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/include/gnunet_core.h 2007-06-08 06:18:58 UTC (rev 4944)
@@ -496,7 +496,7 @@
int (*queryPeerStatus)(const PeerIdentity * node,
unsigned int * bpm,
cron_t * last_seen);
-
+
/**
* Disconnect a particular peer. Sends a HANGUP message to the other
* side and marks all sessionkeys as dead.
Modified: GNUnet/src/include/gnunet_dht_lib.h
===================================================================
--- GNUnet/src/include/gnunet_dht_lib.h 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/include/gnunet_dht_lib.h 2007-06-08 06:18:58 UTC (rev 4944)
@@ -45,7 +45,7 @@
* @param timeout how long to wait until this operation should
* automatically time-out
* @param resultCallback function to call for results,
- * the operation also aborts if the callback returns
+ * the operation also aborts if the callback returns
* SYSERR
* @return number of results on success, SYSERR on error (i.e. timeout)
*/
@@ -63,7 +63,7 @@
* @param key the key to store
* @param expire when should the content expire
* @param value what to store
- * @return OK on success, SYSERR on error
+ * @return OK on success, SYSERR on error
*/
int DHT_LIB_put(struct GC_Configuration * cfg,
struct GE_Context * ectx,
Modified: GNUnet/src/include/gnunet_ecrs_lib.h
===================================================================
--- GNUnet/src/include/gnunet_ecrs_lib.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_ecrs_lib.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -269,13 +269,13 @@
* Convert a NULL-terminated array of keywords
* to an ECRS URI.
*/
-struct ECRS_URI *
+struct ECRS_URI *
ECRS_keywordsToUri(const char * keyword[]);
/**
* Convert a UTF-8 String to a URI.
*/
-struct ECRS_URI *
+struct ECRS_URI *
ECRS_stringToUri(struct GE_Context * ectx,
const char * uri);
@@ -329,7 +329,7 @@
* @param baseURI content offered by the sender
* @param sender identity of the peer with the content
* @param expirationTime how long will the content be offered?
- * @param signer function to call for obtaining
+ * @param signer function to call for obtaining
* RSA signatures for "sender".
* @return the location URI
*/
@@ -351,7 +351,7 @@
* adding the current date (YYYY-MM-DD) after each
* keyword.
*/
-struct ECRS_URI *
+struct ECRS_URI *
ECRS_dateExpandKeywordUri(const struct ECRS_URI * uri);
/**
@@ -453,7 +453,7 @@
* in the meta-data and construct one large keyword URI
* that lists all keywords that can be found in the meta-data).
*/
-struct ECRS_URI *
+struct ECRS_URI *
ECRS_metaDataToUri(const struct ECRS_MetaData * md);
@@ -777,7 +777,7 @@
void * ttClosure); /* download.c */
/**
- * Download parts of a file. Note that this will store
+ * Download parts of a file. Note that this will store
* the blocks at the respective offset in the given file.
* Also, the download is still using the blocking of the
* underlying ECRS encoding. As a result, the download
@@ -790,7 +790,7 @@
* limit the download to exactly those bytes.
*
* @param uri the URI of the file (determines what to download)
- * @param filename where to store the file
+ * @param filename where to store the file
* @param no_temporaries set to YES to disallow generation of temporary files
* @param start starting offset
* @param length length of the download (starting at offset)
Modified: GNUnet/src/include/gnunet_fs_lib.h
===================================================================
--- GNUnet/src/include/gnunet_fs_lib.h 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/include/gnunet_fs_lib.h 2007-06-08 06:18:58 UTC (rev 4944)
@@ -45,7 +45,7 @@
struct FS_SEARCH_CONTEXT;
-struct FS_SEARCH_CONTEXT *
+struct FS_SEARCH_CONTEXT *
FS_SEARCH_makeContext(struct GE_Context * ectx,
struct GC_Configuration * cfg,
struct MUTEX * lock);
@@ -66,7 +66,7 @@
* @param callback method to call for each result
* @param prio priority to use for the search
*/
-struct FS_SEARCH_HANDLE *
+struct FS_SEARCH_HANDLE *
FS_start_search(struct FS_SEARCH_CONTEXT * ctx,
const PeerIdentity * target,
unsigned int type,
Modified: GNUnet/src/include/gnunet_identity_lib.h
===================================================================
--- GNUnet/src/include/gnunet_identity_lib.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_identity_lib.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -59,7 +59,7 @@
Signature * result);
/**
- * Function to request one of the peer's identities
+ * Function to request one of the peer's identities
* (that is, external addresses).
*
* @return SYSERR on error, OK on success
@@ -87,7 +87,7 @@
* be anything!)
* @param last_message if currently connected, when did we
* hear last from this peer (estimate)
- * @param bpmFromPeer 0 if peer is not connected, otherwise
+ * @param bpmFromPeer 0 if peer is not connected, otherwise
* number of bytes per minute that we currently allow
* this peer to sent to us
* @param identity the id of the node
@@ -103,7 +103,7 @@
/**
* Request information about all known peers
*
- * @return SYSERR if iteration was aborted,
+ * @return SYSERR if iteration was aborted,
* otherwise number of peers known
*/
int gnunet_identity_request_peer_infos(struct ClientServerConnection * sock,
Modified: GNUnet/src/include/gnunet_peerinfo_lib.h
===================================================================
--- GNUnet/src/include/gnunet_peerinfo_lib.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_peerinfo_lib.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -43,7 +43,7 @@
* @param name the name of the peer
* @param id identity of the peer
* @param trust trust we have in the peer
- *
+ *
* @return OK to continue, SYSERR to abort iteration
*/
typedef int (*PEERINFO_PeerProcessor)(const char * name,
Modified: GNUnet/src/include/gnunet_setup_lib.h
===================================================================
--- GNUnet/src/include/gnunet_setup_lib.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_setup_lib.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -58,29 +58,29 @@
* Binary type (yes/no).
*/
GNS_Boolean = 4,
-
+
/**
* Unsigned integer type.
*/
GNS_UInt64 = 8,
-
+
/**
* Double value type.
*/
GNS_Double = 16,
/**
- * Free-form string (possibly with suggestions)
+ * Free-form string (possibly with suggestions)
*/
GNS_String = 32,
- /**
+ /**
* Multiple choice (results in space-seperated
* strings, one for each choice).
*/
GNS_MC = 64,
- /**
+ /**
* Single choice (results in individual string
* representing the choice).
*/
@@ -127,7 +127,7 @@
char * def;
/**
- * Set of legal or suggested values for
+ * Set of legal or suggested values for
* "val", NULL termianted.
*/
char ** legalRange;
Modified: GNUnet/src/include/gnunet_sqstore_service.h
===================================================================
--- GNUnet/src/include/gnunet_sqstore_service.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_sqstore_service.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -130,8 +130,8 @@
*
* @param type entries of which type should be considered?
* Use 0 for any type.
- * @param on_demand limit the iteration to entries
- * that not on-demand?
+ * @param on_demand limit the iteration to entries
+ * that not on-demand?
* @param iter never NULL
* @return the number of results, SYSERR if the
* iter is non-NULL and aborted the iteration
@@ -168,7 +168,7 @@
void * closure);
/**
- * Iterate over all the items in the datastore
+ * Iterate over all the items in the datastore
* as fast as possible in a single transaction
* (can lock datastore while this happens, focus
* is on doing it fast).
Modified: GNUnet/src/include/gnunet_testing_lib.h
===================================================================
--- GNUnet/src/include/gnunet_testing_lib.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_testing_lib.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -65,7 +65,7 @@
/**
* Establish a connection between two GNUnet daemons
* (both must run on this machine).
- *
+ *
* @param port1 client port of the first daemon
* @param port2 client port of the second daemon
* @return OK on success, SYSERR on failure
@@ -104,7 +104,7 @@
*
* @return handle used to stop the daemons, NULL on error
*/
-struct DaemonContext *
+struct DaemonContext *
gnunet_testing_start_daemons(const char * transports,
const char * applications,
const char * gnunetd_home_prefix,
@@ -117,7 +117,7 @@
* @return OK on success, SYSERR on error
*/
int gnunet_testing_stop_daemons(struct DaemonContext * peers);
-
+
#if 0 /* keep Emacsens' auto-indent happy */
{
Modified: GNUnet/src/include/gnunet_transport.h
===================================================================
--- GNUnet/src/include/gnunet_transport.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_transport.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -253,7 +253,7 @@
* @return OK on success, SYSERR if the operation failed
*/
int (*connect)(const P2P_hello_MESSAGE * hello,
- TSession ** tsession);
+ TSession ** tsession);
/**
* Send a message to the specified remote node.
@@ -346,7 +346,7 @@
int (*testWouldTry)(TSession * tsession,
unsigned int size,
int important);
-
+
} TransportAPI;
/**
Modified: GNUnet/src/include/gnunet_transport_service.h
===================================================================
--- GNUnet/src/include/gnunet_transport_service.h 2007-06-08 06:18:08 UTC
(rev 4943)
+++ GNUnet/src/include/gnunet_transport_service.h 2007-06-08 06:18:58 UTC
(rev 4944)
@@ -202,8 +202,8 @@
int (*testWouldTry)(TSession * tsession,
unsigned int size,
int important);
-
+
} Transport_ServiceAPI;
#if 0 /* keep Emacsens' auto-indent happy */
Modified: GNUnet/src/include/gnunet_uritrack_lib.h
===================================================================
--- GNUnet/src/include/gnunet_uritrack_lib.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_uritrack_lib.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -124,7 +124,7 @@
* hash-collision in the map, there is a 1:256 chance that we will
* return information from the wrong URI without detecting it).
*/
-enum URITRACK_STATE
+enum URITRACK_STATE
URITRACK_getState(struct GE_Context * ectx,
struct GC_Configuration * cfg,
const struct ECRS_URI * uri);
Modified: GNUnet/src/include/gnunet_util_network.h
===================================================================
--- GNUnet/src/include/gnunet_util_network.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/include/gnunet_util_network.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -426,7 +426,7 @@
* queueing messages (in bytes)
* @return NULL on error
*/
-struct SelectHandle *
+struct SelectHandle *
select_create(const char * desc,
int is_udp,
struct GE_Context * ectx,
@@ -507,9 +507,9 @@
char * network_get_local_ip(struct GC_Configuration * cfg,
struct GE_Context * ectx,
IPaddr * addr);
-
+
#if 0 /* keep Emacsens' auto-indent happy */
{
#endif
Modified: GNUnet/src/server/connection.c
===================================================================
--- GNUnet/src/server/connection.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/server/connection.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -695,7 +695,7 @@
if (stats != NULL)
stats->change(stat_total_allowed_inc,
increment);
- be->available_send_window
+ be->available_send_window
+= increment;
#if 0
printf("Have %u bpm over %llu ms, adding %lld bytes\n",
@@ -707,7 +707,7 @@
if (be->available_send_window > limit) {
if (stats != NULL)
stats->change(stat_total_lost_sent,
- be->available_send_window
+ be->available_send_window
- limit);
be->available_send_window = limit;
}
@@ -819,9 +819,9 @@
4, this is probably a good idea (TM) :-) */
efflen = MALLOC(sizeof(int) * count);
max = available;
- for(i = 0; i < count; i++)
+ for(i = 0; i < count; i++)
if (entries[i]->len > 0)
- max = gcd(max, entries[i]->len);
+ max = gcd(max, entries[i]->len);
GE_ASSERT(ectx, max != 0);
available = available / max;
for(i = 0; i < count; i++)
@@ -919,10 +919,10 @@
delta = load - 50; /* now delta is in [1,50] with 50 == 100% load
*/
if(delta * delta * delta > priority) {
#if DEBUG_POLICY
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Network load is too high (%d%%, priority is %u, require %d), "
- "dropping outgoing.\n",
+ "dropping outgoing.\n",
load,
priority,
delta * delta * delta);
@@ -934,9 +934,9 @@
GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"Network load is ok (%d%%, priority is %u >= %d), "
- "sending outgoing.\n",
- load,
- priority,
+ "sending outgoing.\n",
+ load,
+ priority,
delta * delta * delta);
#endif
return OK; /* allow */
@@ -988,7 +988,7 @@
* @return total number of bytes of messages selected
* including P2P message header.
*/
-static unsigned int
+static unsigned int
selectMessagesToSend(BufferEntry * be,
unsigned int *priority) {
unsigned int totalMessageSize;
@@ -1209,7 +1209,7 @@
entry = be->sendBuffer[i];
if (entry == NULL)
continue;
-
+
if ( (entry->transmissionTime <= expired) ||
(usedBytes > msgCap) ) {
#if DEBUG_CONNECTION
@@ -1266,7 +1266,7 @@
if (entry->knapsackSolution == YES) {
if (entry->callback != NULL) {
tmpMsg = MALLOC(entry->len);
- if (OK == entry->callback(tmpMsg,
+ if (OK == entry->callback(tmpMsg,
entry->closure,
entry->len)) {
entry->callback = NULL;
@@ -1315,7 +1315,7 @@
* @return allocated (caller-frees) buffer with
* permuted SendEntries
*/
-static SendEntry **
+static SendEntry **
permuteSendBuffer(BufferEntry * be,
unsigned int * selected_total) {
unsigned int tailpos;
@@ -1335,8 +1335,8 @@
stotal++;
}
*selected_total = stotal;
- if (stotal == 0)
- return NULL;
+ if (stotal == 0)
+ return NULL;
ret = MALLOC(stotal * sizeof(SendEntry *));
j = 0;
for (i = 0; i < be->sendBufferSize; i++) {
@@ -1349,7 +1349,7 @@
rnd = weak_randomi(stotal);
tmp = ret[j];
ret[j] = ret[rnd];
- ret[rnd] = tmp;
+ ret[rnd] = tmp;
}
tailpos = stotal - 1;
headpos = 0;
@@ -1392,7 +1392,7 @@
FREENONNULL(entry->closure);
FREE(entry);
be->sendBuffer[i] = NULL;
- } else if ( (entry->callback == NULL) &&
+ } else if ( (entry->callback == NULL) &&
(entry->closure == NULL) ) {
FREE(entry);
be->sendBuffer[i] = NULL;
@@ -1551,15 +1551,15 @@
ret = transport->testWouldTry(be->session.tsession,
totalMessageSize,
(priority >= EXTREME_PRIORITY) ? YES : NO);
- /* ret: YES: ok to send, NO: not ready yet, SYSERR: session down
+ /* ret: YES: ok to send, NO: not ready yet, SYSERR: session down
or serious internal error */
if (ret == SYSERR) {
/* transport session is gone! re-establish! */
transport->disconnect(be->session.tsession);
be->session.tsession = NULL;
- if (OK == ensureTransportConnected(be))
+ if (OK == ensureTransportConnected(be))
ret = YES;
- }
+ }
if (YES != ret) {
/* transport's buffer full -- no point in
creating the actual message! */
@@ -1604,7 +1604,7 @@
for (i = 0; i < stotal; i++) {
SendEntry * entry = entries[i];
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
(entry != NULL) &&
(entry->knapsackSolution == YES) &&
(entry->callback == NULL) &&
@@ -1617,15 +1617,15 @@
entry->len);
#endif
memcpy(&plaintextMsg[p],
- entry->closure,
+ entry->closure,
entry->len);
- p += entry->len;
+ p += entry->len;
}
FREE(entries);
entries = NULL;
if (p > totalMessageSize) {
GE_BREAK(ectx, 0);
- FREE(plaintextMsg);
+ FREE(plaintextMsg);
be->inSendBuffer = NO;
return NO;
}
@@ -1644,7 +1644,7 @@
if ( (rsi + p < p) ||
(rsi + p > totalMessageSize) ) {
GE_BREAK(ectx, 0);
- FREE(plaintextMsg);
+ FREE(plaintextMsg);
be->inSendBuffer = NO;
return NO;
}
@@ -1653,10 +1653,10 @@
pos = pos->next;
}
if ( ( (be->session.mtu != 0) &&
- (p > be->session.mtu) )
+ (p > be->session.mtu) )
|| (p > totalMessageSize) ) {
GE_BREAK(ectx, 0);
- FREE(plaintextMsg);
+ FREE(plaintextMsg);
be->inSendBuffer = NO;
return NO;
}
@@ -1664,7 +1664,7 @@
/* finally padd with noise */
if ( (p + sizeof(MESSAGE_HEADER) <= totalMessageSize) &&
(p < totalMessageSize) &&
- (p + sizeof(MESSAGE_HEADER) > p) &&
+ (p + sizeof(MESSAGE_HEADER) > p) &&
(disable_random_padding == NO) ) {
MESSAGE_HEADER part;
unsigned short noiseLen = totalMessageSize - p;
@@ -1684,14 +1684,14 @@
(p > be->session.mtu) )
|| (p > totalMessageSize) ) {
GE_BREAK(ectx, 0);
- FREE(plaintextMsg);
+ FREE(plaintextMsg);
be->inSendBuffer = NO;
return NO;
}
encryptedMsg = MALLOC(p);
hash(&p2pHdr->sequenceNumber,
- p - sizeof(HashCode512),
+ p - sizeof(HashCode512),
(HashCode512 *) encryptedMsg);
ret = encryptBlock(&p2pHdr->sequenceNumber,
p - sizeof(HashCode512),
@@ -1707,7 +1707,7 @@
ret));
#endif
if(stats != NULL)
- stats->change(stat_encrypted,
+ stats->change(stat_encrypted,
p - sizeof(HashCode512));
GE_ASSERT(ectx, be->session.tsession != NULL);
#if DEBUG_CONNECTION
@@ -2047,8 +2047,8 @@
se->callback = NULL;
se->closure = MALLOC(sizeof(P2P_hangup_MESSAGE));
se->knapsackSolution = NO;
- memcpy(se->closure,
- &hangup,
+ memcpy(se->closure,
+ &hangup,
sizeof(P2P_hangup_MESSAGE));
appendToBuffer(be, se);
if(stats != NULL)
@@ -2487,7 +2487,7 @@
* frequency. However, on my system, larger values significantly
* impact the performance of the UDP transport for large (fragmented)
* messages -- and 10ms does not cause any noticeable CPU load during
- * testing.
+ * testing.
*/
#define CDL_FREQUENCY (10 * cronMILLIS)
@@ -2508,7 +2508,7 @@
unsigned long long total_send_buffer_size;
int load_nup;
int load_cpu;
-
+
load_cpu = os_cpu_get_load(ectx, cfg);
load_nup = os_network_monitor_get_load(load_monitor,
Upload);
@@ -2599,7 +2599,7 @@
pos = pos->next;
}
FREE(msgBuf);
- }
+ }
break;
default: /* not up, not down - partial SETKEY exchange */
if ( (now > root->isAlive) &&
@@ -2781,7 +2781,7 @@
if (be->available_send_window > (long long) be->max_bpm * MAX_BUF_FACT) {
if (stats != NULL)
stats->change(stat_total_lost_sent,
- be->available_send_window
+ be->available_send_window
- (long long) be->max_bpm * MAX_BUF_FACT);
be->available_send_window = (long long) be->max_bpm * MAX_BUF_FACT;
be->last_bps_update = get_time();
@@ -2864,8 +2864,8 @@
} else { /* for receiving */
if ( ((be->status & STAT_SETKEY_RECEIVED) == 0) ||
(be->skey_remote_created < age) ) {
- if (0 != memcmp(key,
- &be->skey_remote,
+ if (0 != memcmp(key,
+ &be->skey_remote,
sizeof(SESSIONKEY))) {
be->skey_remote = *key;
be->lastSequenceNumberReceived = 0;
@@ -3276,8 +3276,8 @@
be = CONNECTION_buffer_[i];
while(be != NULL) {
#if DEBUG_CONNECTION
- GE_LOG(ectx,
- GE_DEBUG | GE_REQUEST | GE_USER,
+ GE_LOG(ectx,
+ GE_DEBUG | GE_REQUEST | GE_USER,
"Closing connection: shutdown\n");
#endif
shutdownConnection(be);
@@ -3366,7 +3366,7 @@
ttype = 0;
if(tmp->session.tsession != NULL)
ttype = tmp->session.tsession->ttype;
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_INFO | GE_REQUEST | GE_USER,
"CONNECTION-TABLE: %3d-%1d-%2d-%4ds"
" (of %ds) BPM %4llu %8ut-%3u: %s-%s-%s\n",
Modified: GNUnet/src/server/gnunet-peer-info.c
===================================================================
--- GNUnet/src/server/gnunet-peer-info.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/server/gnunet-peer-info.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -91,7 +91,7 @@
P2P_hello_MESSAGE_size(hello) - sizeof(Signature) -
sizeof(PublicKey) - sizeof(MESSAGE_HEADER),
&hello->signature,
&hello->publicKey)) {
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_WARNING | GE_BULK | GE_USER,
_("hello message invalid (signature invalid).\n"));
}
Modified: GNUnet/src/server/gnunet-transport-check.c
===================================================================
--- GNUnet/src/server/gnunet-transport-check.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/server/gnunet-transport-check.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -224,7 +224,7 @@
int len;
PeerIdentity peer;
unsigned long long verbose;
-
+
stats[0]++; /* one more seen */
if (NO == transport->isAvailable(ntohs(xhello->protocol))) {
GE_LOG(ectx,
@@ -233,8 +233,8 @@
ntohs(xhello->protocol));
return;
}
- if (ntohs(xhello->protocol) == NAT_PROTOCOL_NUMBER)
- return; /* NAT cannot be tested */
+ if (ntohs(xhello->protocol) == NAT_PROTOCOL_NUMBER)
+ return; /* NAT cannot be tested */
stats[1]++; /* one more with transport 'available' */
GC_get_configuration_value_number(cfg,
@@ -257,17 +257,17 @@
fprintf(stderr, ".");
hello = MALLOC(ntohs(xhello->header.size));
memcpy(hello,
- xhello,
+ xhello,
ntohs(xhello->header.size));
myHello = transport->createhello(ntohs(xhello->protocol));
- if (myHello == NULL)
+ if (myHello == NULL)
/* try NAT */
myHello = transport->createhello(NAT_PROTOCOL_NUMBER);
if (myHello == NULL) {
FREE(hello);
return;
- }
+ }
if (verbose > 0)
fprintf(stderr, ".");
tsession = NULL;
@@ -333,7 +333,7 @@
SEMAPHORE_DOWN(sem, YES);
if (verbose > 0) {
- if (ok != YES)
+ if (ok != YES)
FPRINTF(stderr,
_("Timeout after %llums.\n"),
timeout);
Modified: GNUnet/src/server/gnunet-update.c
===================================================================
--- GNUnet/src/server/gnunet-update.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/server/gnunet-update.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -197,7 +197,7 @@
return;
}
-
+
/* enforce filesystem limits */
capFSQuotaSize(ectx, cfg);
Modified: GNUnet/src/server/gnunetd.c
===================================================================
--- GNUnet/src/server/gnunetd.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/server/gnunetd.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -92,14 +92,14 @@
static int post_detach() {
- if (OK != changeUser(ectx, cfg))
- return SYSERR;
- if (OK != checkPermissions(ectx, cfg))
- return SYSERR;
+ if (OK != changeUser(ectx, cfg))
+ return SYSERR;
+ if (OK != checkPermissions(ectx, cfg))
+ return SYSERR;
mon = os_network_monitor_create(ectx,
cfg);
- if (mon == NULL)
- return SYSERR;
+ if (mon == NULL)
+ return SYSERR;
return OK;
}
@@ -115,7 +115,7 @@
cfg,
filedes)) )
return SYSERR;
- if (NO != debug_flag)
+ if (NO != debug_flag)
os_write_pid_file(ectx,
cfg,
(unsigned int)getpid());
@@ -132,14 +132,14 @@
GE_ASSERT(ectx,
cron != NULL);
#ifndef WINDOWS
- shc_hup = signal_handler_install(SIGHUP,
+ shc_hup = signal_handler_install(SIGHUP,
&reread_config);
#endif
if (OK != initCore(ectx,
cfg,
cron,
mon)) {
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_FATAL | GE_USER | GE_IMMEDIATE,
_("Core initialization failed.\n"));
@@ -156,10 +156,10 @@
NO);
return SYSERR;
}
-
+
/* enforce filesystem limits */
capFSQuotaSize(ectx, cfg);
-
+
initConnection(ectx, cfg, mon, cron);
loadApplicationModules();
if (NO == debug_flag)
@@ -267,17 +267,17 @@
NO);
ull = GE_getKIND(user_log_level);
ull |= (ull - 1); /* set bits for all lower log-levels */
- if (dev == YES)
- ull |= GE_DEVELOPER | GE_REQUEST;
- if (loud_flag == 1)
+ if (dev == YES)
+ ull |= GE_DEVELOPER | GE_REQUEST;
+ if (loud_flag == 1)
ectx = GE_create_context_stderr(YES,
GE_ALL);
else
ectx = GE_create_context_stderr(YES,
- GE_USER | GE_ADMIN
- | ull
+ GE_USER | GE_ADMIN
+ | ull
| GE_BULK | GE_IMMEDIATE);
- GE_setDefaultContext(ectx);
+ GE_setDefaultContext(ectx);
}
setFdLimit(ectx, cfg);
if (OK != checkUpToDate(ectx,
@@ -289,11 +289,11 @@
GNUNET_fini(ectx, cfg);
return 1;
}
-
+
#ifdef MINGW
- if (GC_get_configuration_value_yesno(cfg,
+ if (GC_get_configuration_value_yesno(cfg,
"GNUNETD",
- "WINSERVICE",
+ "WINSERVICE",
NO) == YES) {
SERVICE_TABLE_ENTRY DispatchTable[] =
{{"GNUnet", ServiceMain}, {NULL, NULL}};
Modified: GNUnet/src/server/startup.c
===================================================================
--- GNUnet/src/server/startup.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/server/startup.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -50,12 +50,12 @@
* @param cfg configuration, may be NULL if in service mode
* @param sig signal code that causes shutdown, optional
*/
-void shutdown_gnunetd(struct GC_Configuration * cfg,
+void shutdown_gnunetd(struct GC_Configuration * cfg,
int sig) {
#ifdef MINGW
- if (!cfg || GC_get_configuration_value_yesno(cfg,
- "GNUNETD",
- "WINSERVICE",
+ if (!cfg || GC_get_configuration_value_yesno(cfg,
+ "GNUNETD",
+ "WINSERVICE",
NO) == YES) {
/* If GNUnet runs as service, only the
Service Control Manager is allowed
@@ -68,7 +68,7 @@
if (GNControlService(hService, SERVICE_CONTROL_STOP, &theStat))
{
/* Success */
-
+
/* The Service Control Manager will call
gnunetd.c::ServiceCtrlHandler(), which calls
this function again. We then stop the gnunetd. */
@@ -78,7 +78,7 @@
but we don't care.
Just shut the gnunetd process down. */
}
-
+
/* Acknowledge the shutdown request */
theServiceStatus.dwCurrentState = SERVICE_STOP_PENDING;
GNSetServiceStatus(hService, &theServiceStatus);
@@ -174,7 +174,7 @@
unsigned long long quota, cap;
char *afsdir, fs[MAX_PATH + 1];
DWORD flags;
-
+
if (-1 == GC_get_configuration_value_number(cfg,
"FS",
"QUOTA",
@@ -190,7 +190,7 @@
VAR_DAEMON_DIRECTORY "/data/fs/",
&afsdir);
GE_ASSERT(ectx, strlen(afsdir) > 2);
-
+
/* get root directory */
afsdir[3] = '\0';
@@ -207,10 +207,10 @@
_("Unable to obtain filesystem information for `%s': %u\n"),
afsdir,
GetLastError());
-
+
return;
}
-
+
if (strncasecmp(fs, "NTFS", 4) == 0)
cap = 0;
else if (strcasecmp(fs, "FAT32") == 0)
@@ -225,13 +225,13 @@
"contact address@hidden"),
fs,
afsdir);
-
+
if (!(flags & FILE_PERSISTENT_ACLS))
cap = 1500;
else
cap = 0;
}
-
+
if ((cap != 0) && (cap < quota)) {
GE_LOG(ectx,
GE_WARNING | GE_ADMIN | GE_USER | GE_IMMEDIATE,
@@ -240,7 +240,7 @@
"a NTFS partition!\n"),
cap / 1000,
fs);
-
+
GC_set_configuration_value_number(cfg,
ectx,
"FS",
@@ -259,7 +259,7 @@
int mode) {
char * fn;
int i;
-
+
GC_get_configuration_value_filename(cfg,
section,
option,
@@ -276,7 +276,7 @@
while ( (i > 1) &&
(fn[i] != DIR_SEPARATOR) )
i--;
- fn[i] = '\0';
+ fn[i] = '\0';
mode = X_OK | W_OK;
}
if (0 != ACCESS(fn, mode)) {
@@ -300,7 +300,7 @@
"GNUNETD_HOME",
"/var/lib/gnunet",
YES,
- W_OK | X_OK);
+ W_OK | X_OK);
CHECK("GNUNETD",
"LOGFILE",
"$GNUNETD_HOME/daemon-logs",
Modified: GNUnet/src/server/version.c
===================================================================
--- GNUnet/src/server/version.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/server/version.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -199,8 +199,8 @@
memcpy(version, VERSION, strlen(VERSION)+1);
getVersionHash(cfg,
&enc);
- memcpy(&version[strlen(VERSION)+1],
- &enc,
+ memcpy(&version[strlen(VERSION)+1],
+ &enc,
sizeof(EncName));
UNLINK(fn);
disk_file_write(ectx,
Modified: GNUnet/src/setup/gtk/gconf.c
===================================================================
--- GNUnet/src/setup/gtk/gconf.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/setup/gtk/gconf.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -156,7 +156,7 @@
&it,
SETUP_TEXT_VIS, TRUE,
SETUP_COMBO_VIS, TRUE,
- -1);
+ -1);
break;
case GNS_MC:
cmodel = gtk_list_store_new(1,
@@ -176,7 +176,7 @@
j *= 2;
}
tmp = MALLOC(tmpl);
- /* For now, only allow multiple choice for less than 12 entries...
+ /* For now, only allow multiple choice for less than 12 entries...
(10 are needed for applications!) */
if (i < 12) {
while (--j >= 0) {
@@ -207,7 +207,7 @@
&it,
SETUP_TEXT_VIS, TRUE,
SETUP_COMBO_VIS, TRUE,
- -1);
+ -1);
break;
case GNS_SC:
cmodel = gtk_list_store_new(1,
Modified: GNUnet/src/setup/lib/gns.c
===================================================================
--- GNUnet/src/setup/lib/gns.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/setup/lib/gns.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -166,7 +166,7 @@
}
break;
}
- case GNS_String:
+ case GNS_String:
case GNS_MC: {
char * val;
@@ -175,7 +175,7 @@
option,
pos->value.String.def,
&val))
- return SYSERR;
+ return SYSERR;
FREE(pos->value.String.val);
pos->value.String.val = val;
break;
@@ -188,8 +188,8 @@
option,
(const char**)
pos->value.String.legalRange,
pos->value.String.def,
- &ival))
- return SYSERR;
+ &ival))
+ return SYSERR;
FREE(pos->value.String.val);
pos->value.String.val = STRDUP(ival);
break;
Modified: GNUnet/src/setup/lib/tree.c
===================================================================
--- GNUnet/src/setup/lib/tree.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/setup/lib/tree.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -140,7 +140,7 @@
return scm_from_uint64(t->value.UInt64.val);
case GNS_Double:
return scm_from_double(t->value.Double.val);
- case GNS_String:
+ case GNS_String:
case GNS_MC:
case GNS_SC:
return scm_from_locale_string(t->value.String.val);
@@ -175,7 +175,7 @@
if ( (opt == NULL) ||
(sec == NULL) ) {
GE_BREAK(NULL, 0);
- return SCM_EOL;
+ return SCM_EOL;
}
t = tree_lookup(tc->root,
sec,
@@ -269,7 +269,7 @@
SCM_ASSERT(scm_list_p(range), range, SCM_ARGn, "build_tree_node");
len = scm_to_int(scm_length(range));
for (i=0;i<len;i++)
- SCM_ASSERT(scm_string_p(scm_list_ref(range,
+ SCM_ASSERT(scm_string_p(scm_list_ref(range,
scm_from_signed_integer(i))),
range, SCM_ARGn, "build_tree_node");
} else if (scm_is_integer(value)) {
@@ -446,7 +446,7 @@
putenv(env);
free(env);
#endif
-
+
scm_init_guile();
tc_tag = scm_make_smob_type ("tc", 0);
Modified: GNUnet/src/setup/ncurses/mconf.c
===================================================================
--- GNUnet/src/setup/ncurses/mconf.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/setup/ncurses/mconf.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -289,7 +289,7 @@
default:
return;
}
- break;
+ break;
case GNS_MC:
/* begin multiple choice */
val = &pos->value;
@@ -307,9 +307,9 @@
tlen += strlen(val->String.legalRange[i]) + 1;
items[i].help = "";
items[i].state = 0;
-
+
tmp = val->String.val;
- while (NULL != (tmp = strstr(tmp,
+ while (NULL != (tmp = strstr(tmp,
val->String.legalRange[i]))) {
if ( ( (tmp == val->String.val) ||
(tmp[-1] == ' ') ) &&
@@ -335,7 +335,7 @@
switch (st) {
case DLG_EXIT_OK:
tmp = MALLOC(tlen);
- tmp[0] = '\0';
+ tmp[0] = '\0';
i = 0;
while (val->String.legalRange[i] != NULL) {
if (items[i].state == 1) {
@@ -371,7 +371,7 @@
return;
}
FREE(items);
- break;
+ break;
case GNS_Double:
fitem.text = MALLOC(64);
SNPRINTF(fitem.text,
Modified: GNUnet/src/transports/http.c
===================================================================
--- GNUnet/src/transports/http.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/http.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -51,7 +51,7 @@
* Default maximum size of the HTTP read and write buffer.
*/
#define HTTP_BUF_SIZE (64 * 1024)
-
+
/**
* Host-Address in a HTTP network.
*/
@@ -115,7 +115,7 @@
unsigned int users;
/**
- * Number of valid bytes in rbuff1
+ * Number of valid bytes in rbuff1
*/
unsigned int rpos1;
@@ -171,7 +171,7 @@
* GET session response handle
*/
struct MHD_Response * get;
-
+
} server;
struct {
@@ -188,7 +188,7 @@
/**
* URL of the get and put operations.
- */
+ */
char * url;
} client;
@@ -238,7 +238,7 @@
static unsigned int tsessionArrayLength;
/**
- * Blacklist configuration
+ * Blacklist configuration
*/
static struct CIDRNetwork * filteredNetworks_;
@@ -302,7 +302,7 @@
*/
static int httpDisconnect(TSession * tsession) {
HTTPSession * httpsession = tsession->internal;
-
+
if (httpsession != NULL) {
MUTEX_LOCK(httpsession->lock);
httpsession->users--;
@@ -346,7 +346,7 @@
0,
65535,
1080,
- &port))
+ &port))
port = 1080;
return (unsigned short) port;
}
@@ -446,10 +446,10 @@
GE_LOG(coreAPI->ectx,
GE_WARNING | GE_ADMIN | GE_USER | GE_BULK,
_("HTTP: Could not determine my public IP address.\n"));
- return NULL;
+ return NULL;
}
#if DEBUG_HTTP
- GE_LOG(coreAPI->ectx,
+ GE_LOG(coreAPI->ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"HTTP uses IP address %u.%u.%u.%u.\n",
PRIP(ntohl(*(int*)&haddr->ip)));
@@ -502,7 +502,7 @@
session->wpos -= max;
session->woff += max;
session->lastUse = get_time();
- if (session->wpos == 0)
+ if (session->wpos == 0)
session->woff = 0;
MUTEX_UNLOCK(session->lock);
return max;
@@ -617,8 +617,8 @@
have -= cpy;
poff += cpy;
}
- if (httpSession->rpos1 < sizeof(MESSAGE_HEADER))
- break;
+ if (httpSession->rpos1 < sizeof(MESSAGE_HEADER))
+ break;
hdr = (MESSAGE_HEADER *) httpSession->rbuff1;
GROW(httpSession->rbuff2,
httpSession->rsize2,
@@ -638,7 +638,7 @@
have -= cpy;
poff += cpy;
}
- if (httpSession->rpos2 < ntohs(hdr->size))
+ if (httpSession->rpos2 < ntohs(hdr->size))
break;
mp = MALLOC(sizeof(P2P_PACKET));
mp->msg = httpSession->rbuff2;
@@ -650,13 +650,13 @@
httpSession->rsize2 = 0;
httpSession->rpos1 = 0;
}
- } else
+ } else
return MHD_NO; /* must be get or put! */
return MHD_YES;
}
/**
- * Process downloaded bits
+ * Process downloaded bits
*/
static size_t
receiveContentCallback(void * ptr,
@@ -670,7 +670,7 @@
size_t cpy;
MESSAGE_HEADER * hdr;
P2P_PACKET * mp;
-
+
while (have > 0) {
if (httpSession->rpos1 < sizeof(MESSAGE_HEADER)) {
cpy = sizeof(MESSAGE_HEADER) - httpSession->rpos1;
@@ -704,7 +704,7 @@
have -= cpy;
poff += cpy;
}
- if (httpSession->rpos2 < ntohs(hdr->size))
+ if (httpSession->rpos2 < ntohs(hdr->size))
return size * nmemb;
mp = MALLOC(sizeof(P2P_PACKET));
mp->msg = httpSession->rbuff2;
@@ -745,7 +745,7 @@
if (max == 0) {
/* if we have nothing to sent, this will terminate
the session (CURL API requires this) */
- httpSession->cs.client.put = NULL;
+ httpSession->cs.client.put = NULL;
}
MUTEX_UNLOCK(httpSession->lock);
return max;
@@ -797,9 +797,9 @@
proxy);
CURL_EASY_SETOPT(curl_get,
CURLOPT_BUFFERSIZE,
- 32 * 1024);
+ 32 * 1024);
if (0 == strncmp(url,
- "http",
+ "http",
4))
CURL_EASY_SETOPT(curl_get,
CURLOPT_USERAGENT,
@@ -816,7 +816,7 @@
CURL_EASY_SETOPT(curl_get,
CURLOPT_WRITEDATA,
httpSession);
- if (ret != CURLE_OK)
+ if (ret != CURLE_OK)
goto cleanup;
/* FIXME: should we queue here or wait until we have data!? */
@@ -864,13 +864,13 @@
return SYSERR;
}
-static CURL *
+static CURL *
create_curl_put(HTTPSession * httpSession) {
CURL * curl_put;
CURLcode ret;
curl_put = curl_easy_init();
- if (curl_put == NULL)
+ if (curl_put == NULL)
return NULL;
CURL_EASY_SETOPT(curl_put,
CURLOPT_FAILONERROR,
@@ -886,7 +886,7 @@
CURLOPT_BUFFERSIZE,
32 * 1024);
if (0 == strncmp(httpSession->cs.client.url,
- "http",
+ "http",
4))
CURL_EASY_SETOPT(curl_put,
CURLOPT_USERAGENT,
@@ -898,7 +898,7 @@
CURLOPT_CONNECTTIMEOUT,
150L);
CURL_EASY_SETOPT(curl_put,
- CURLOPT_INFILESIZE_LARGE,
+ CURLOPT_INFILESIZE_LARGE,
0);
CURL_EASY_SETOPT(curl_put,
CURLOPT_READFUNCTION,
@@ -937,7 +937,7 @@
}
MUTEX_LOCK(httpSession->lock);
if (httpSession->cs.client.put == NULL) {
- /* first data to send, add PUT to multi set! */
+ /* first data to send, add PUT to multi set! */
curl_put = create_curl_put(httpSession);
if (curl_put == NULL) {
MUTEX_UNLOCK(httpSession->lock);
@@ -959,13 +959,13 @@
return SYSERR;
}
}
-
+
if ( (httpSession->wsize > HTTP_BUF_SIZE) &&
(important == NO) ) {
if (stats != NULL)
stats->change(stat_bytesDropped,
size);
- MUTEX_UNLOCK(httpSession->lock);
+ MUTEX_UNLOCK(httpSession->lock);
return NO;
}
if (httpSession->wsize >= httpSession->wpos + size) {
@@ -1054,7 +1054,7 @@
break;
running = 0;
curl_multi_perform(curl_multi, &running);
- }
+ }
return NULL;
}
@@ -1069,7 +1069,7 @@
(http_running == YES) )
return SYSERR;
curl_multi = curl_multi_init();
- if (curl_multi == NULL)
+ if (curl_multi == NULL)
return SYSERR;
port = getGNUnetHTTPPort();
if ( (mhd_daemon == NULL) &&
@@ -1145,7 +1145,7 @@
/**
* Convert HTTP address to a string.
*/
-static char *
+static char *
addressToString(const P2P_hello_MESSAGE * hello,
int do_resolve) {
char * ret;
@@ -1163,7 +1163,7 @@
serverAddr.sin_family = AF_INET;
memcpy(&serverAddr.sin_addr,
haddr,
- sizeof(IPaddr));
+ sizeof(IPaddr));
serverAddr.sin_port = haddr->port;
if (0 == getnameinfo((const struct sockaddr*) &serverAddr,
sizeof(struct sockaddr_in),
@@ -1182,7 +1182,7 @@
AF_INET);
if (ent != NULL)
hn = ent->h_name;
- }
+ }
#endif
#endif
n = 4*4+7+6 + strlen(hn) + 10;
@@ -1211,7 +1211,7 @@
* The exported method. Makes the core api available
* via a global and returns the udp transport API.
*/
-TransportAPI *
+TransportAPI *
inittransport_http(CoreAPIForTransport * core) {
static TransportAPI httpAPI;
@@ -1241,12 +1241,12 @@
"UPNP",
YES) == YES) {
upnp = coreAPI->requestService("upnp");
-
+
if (upnp == NULL) {
GE_LOG(coreAPI->ectx,
GE_ERROR | GE_USER | GE_IMMEDIATE,
_("The UPnP service could not be loaded. To disable UPnP, set the
" \
- "configuration option \"UPNP\" in section \"HTTP\" to
\"NO\"\n"));
+ "configuration option \"UPNP\" in section \"HTTP\" to
\"NO\"\n"));
}
}
Modified: GNUnet/src/transports/ip.c
===================================================================
--- GNUnet/src/transports/ip.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/ip.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -50,7 +50,7 @@
if (lastError + 30 * cronSECONDS > now)
return SYSERR;
ips = network_get_local_ip(cfg,
- ectx,
+ ectx,
&myAddress);
if (ips == NULL) {
GE_LOG(ectx,
Modified: GNUnet/src/transports/ip6.c
===================================================================
--- GNUnet/src/transports/ip6.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/ip6.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -112,8 +112,8 @@
ifa_ptr = ifa_first;
for (ifa_ptr = ifa_first; ifa_ptr != NULL; ifa_ptr = ifa_ptr->ifa_next) {
- if (ifa_ptr->ifa_name != NULL &&
- ifa_ptr->ifa_addr != NULL &&
+ if (ifa_ptr->ifa_name != NULL &&
+ ifa_ptr->ifa_addr != NULL &&
(ifa_ptr->ifa_flags & IFF_UP) != 0) {
if (strcmp(interfaces, (char *)ifa_ptr->ifa_name) != 0)
continue;
@@ -186,7 +186,7 @@
}
#if HAVE_GETIFADDRS && HAVE_FREEIFADDRS
if (retval == SYSERR)
- if (OK == getAddress6FromGetIfAddrs(cfg,
+ if (OK == getAddress6FromGetIfAddrs(cfg,
ectx,
address))
retval = OK;
Modified: GNUnet/src/transports/tcp.c
===================================================================
--- GNUnet/src/transports/tcp.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/tcp.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -37,7 +37,7 @@
/**
* after how much time of the core not being associated with a tcp
* connection anymore do we close it?
- *
+ *
* Needs to be larger than SECONDS_INACTIVE_DROP in
* core's connection.s
*/
@@ -112,7 +112,7 @@
ip);
MUTEX_UNLOCK(tcpblacklistlock);
#if DEBUG_TCP
- if (ret != OK)
+ if (ret != OK)
GE_LOG(ectx,
GE_DEBUG | GE_ADMIN | GE_BULK,
"Rejecting connection from address %u.%u.%u.%u (blacklisted)\n",
@@ -229,7 +229,7 @@
&enc);
#endif
return SYSERR; /* obviously invalid */
- }
+ }
return OK;
}
@@ -272,7 +272,7 @@
GE_LOG(ectx,
GE_WARNING | GE_ADMIN | GE_USER | GE_BULK,
_("TCP: Could not determine my public IP address.\n"));
- return NULL;
+ return NULL;
}
#if DEBUG_TCP
GE_LOG(ectx,
@@ -344,7 +344,7 @@
sizeof(soaddr));
soaddr.sin_family = AF_INET;
- GE_ASSERT(ectx,
+ GE_ASSERT(ectx,
sizeof(struct in_addr) == sizeof(IPaddr));
memcpy(&soaddr.sin_addr,
&haddr->ip,
@@ -498,7 +498,7 @@
/**
* Convert TCP address to a string.
*/
-static char *
+static char *
addressToString(const P2P_hello_MESSAGE * hello,
int do_resolve) {
char * ret;
@@ -516,7 +516,7 @@
serverAddr.sin_family = AF_INET;
memcpy(&serverAddr.sin_addr,
haddr,
- sizeof(IPaddr));
+ sizeof(IPaddr));
serverAddr.sin_port = haddr->port;
if (0 == getnameinfo((const struct sockaddr*) &serverAddr,
sizeof(struct sockaddr_in),
@@ -535,7 +535,7 @@
AF_INET);
if (ent != NULL)
hn = ent->h_name;
- }
+ }
#endif
#endif
n = 4*4+6+6 + strlen(hn) + 10;
@@ -587,7 +587,7 @@
"UPNP",
YES) == YES) {
upnp = coreAPI->requestService("upnp");
-
+
if (upnp == NULL) {
GE_LOG(ectx,
GE_ERROR | GE_USER | GE_IMMEDIATE,
Modified: GNUnet/src/transports/tcp6.c
===================================================================
--- GNUnet/src/transports/tcp6.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/tcp6.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -36,7 +36,7 @@
/**
* after how much time of the core not being associated with a tcp6
* connection anymore do we close it?
- *
+ *
* Needs to be larger than SECONDS_INACTIVE_DROP in
* core's connection.s
*/
@@ -450,10 +450,10 @@
/**
* Convert TCP6 address to a string.
*/
-static char *
+static char *
addressToString(const P2P_hello_MESSAGE * hello,
int do_resolve) {
-
+
char * ret;
char inet6[INET6_ADDRSTRLEN];
const Host6Address * haddr = (const Host6Address*) &hello[1];
@@ -491,7 +491,7 @@
AF_INET6);
if (ent != NULL)
hn = ent->h_name;
- }
+ }
#endif
#endif
n = INET6_ADDRSTRLEN + 16 + strlen(hn) + 10;
Modified: GNUnet/src/transports/tcp_helper.c
===================================================================
--- GNUnet/src/transports/tcp_helper.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/tcp_helper.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -379,14 +379,14 @@
GE_BREAK(ectx, 0);
return SYSERR;
}
- if (selector == NULL)
+ if (selector == NULL)
return SYSERR;
if (size == 0) {
GE_BREAK(ectx, 0);
return SYSERR;
}
- if (tcpSession->sock == NULL)
- return SYSERR; /* other side closed connection */
+ if (tcpSession->sock == NULL)
+ return SYSERR; /* other side closed connection */
return select_would_try(selector,
tcpSession->sock,
size,
Modified: GNUnet/src/transports/udp.c
===================================================================
--- GNUnet/src/transports/udp.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/udp.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -233,7 +233,7 @@
sizeof(IPaddr))) )
return SYSERR; /* obviously invalid */
#if DEBUG_UDP
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_USER | GE_BULK,
"Verified UDP HELLO from %u.%u.%u.%u:%u.\n",
PRIP(ntohl(*(int*)&haddr->senderIP.addr)),
@@ -273,7 +273,7 @@
GE_LOG(ectx,
GE_WARNING | GE_ADMIN | GE_USER | GE_BULK,
_("UDP: Could not determine my public IP address.\n"));
- return NULL;
+ return NULL;
}
#if DEBUG_UDP
GE_LOG(ectx,
@@ -462,7 +462,7 @@
/**
* Convert UDP address to a string.
*/
-static char *
+static char *
addressToString(const P2P_hello_MESSAGE * hello,
int do_resolve) {
char * ret;
@@ -481,7 +481,7 @@
serverAddr.sin_family = AF_INET;
memcpy(&serverAddr.sin_addr,
haddr,
- sizeof(IPaddr));
+ sizeof(IPaddr));
serverAddr.sin_port = haddr->senderPort;
if (0 == getnameinfo((const struct sockaddr* ) &serverAddr,
sizeof(struct sockaddr_in),
@@ -500,7 +500,7 @@
AF_INET);
if (ent != NULL)
hn = ent->h_name;
- }
+ }
#endif
#endif
n = 4*4+6+6 + strlen(hn) + 10;
@@ -532,10 +532,10 @@
* The exported method. Makes the core api available via a global and
* returns the udp transport API.
*/
-TransportAPI *
+TransportAPI *
inittransport_udp(CoreAPIForTransport * core) {
unsigned long long mtu;
-
+
ectx = core->ectx;
cfg = core->cfg;
load_monitor = core->load_monitor;
@@ -545,8 +545,8 @@
if (-1 == GC_get_configuration_value_number(cfg,
"UDP",
"MTU",
- sizeof(UDPMessage)
- + P2P_MESSAGE_OVERHEAD
+ sizeof(UDPMessage)
+ + P2P_MESSAGE_OVERHEAD
+ sizeof(MESSAGE_HEADER) + 32,
65500,
MESSAGE_SIZE,
@@ -564,7 +564,7 @@
"UPNP",
YES) == YES) {
upnp = coreAPI->requestService("upnp");
-
+
if (upnp == NULL)
GE_LOG(ectx,
GE_ERROR | GE_USER | GE_IMMEDIATE,
Modified: GNUnet/src/transports/udp6.c
===================================================================
--- GNUnet/src/transports/udp6.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/udp6.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -442,7 +442,7 @@
/**
* Convert UDP6 address to a string.
*/
-static char *
+static char *
addressToString(const P2P_hello_MESSAGE * hello,
int do_resolve) {
char * ret;
@@ -481,7 +481,7 @@
AF_INET);
if (ent != NULL)
hn = ent->h_name;
- }
+ }
#endif
#endif
n = INET6_ADDRSTRLEN + 16 + strlen(hn) + 10;
Modified: GNUnet/src/transports/upnp/error.c
===================================================================
--- GNUnet/src/transports/upnp/error.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/upnp/error.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -4,26 +4,26 @@
/**
* Map gaim logger to GNUnet logger.
*/
-void gaim_debug_error(char * facility,
+void gaim_debug_error(char * facility,
char * format,
...) {
GE_LOG(NULL,
- GE_WARNING | GE_DEVELOPER | GE_ADMIN | GE_BULK,
+ GE_WARNING | GE_DEVELOPER | GE_ADMIN | GE_BULK,
"%s: %s\n",
facility,
format);
}
-
+
/**
* Map gaim logger to GNUnet logger.
*/
-void gaim_debug_info(char * facility,
+void gaim_debug_info(char * facility,
char * format,
...) {
GE_LOG(NULL,
- GE_INFO | GE_ADMIN | GE_BULK,
+ GE_INFO | GE_ADMIN | GE_BULK,
"%s: %s\n",
facility,
format);
}
-
+
Modified: GNUnet/src/transports/upnp/error.h
===================================================================
--- GNUnet/src/transports/upnp/error.h 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/upnp/error.h 2007-06-08 06:18:58 UTC (rev 4944)
@@ -5,7 +5,7 @@
/**
* Map gaim logger to GNUnet logger.
*/
-void gaim_debug_error(char * facility,
+void gaim_debug_error(char * facility,
char * format,
...);
@@ -13,6 +13,6 @@
/**
* Map gaim logger to GNUnet logger.
*/
-void gaim_debug_info(char * facility,
+void gaim_debug_info(char * facility,
char * format,
...);
Modified: GNUnet/src/transports/upnp/init.c
===================================================================
--- GNUnet/src/transports/upnp/init.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/upnp/init.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -104,12 +104,12 @@
unsigned int i;
MUTEX_LOCK(lock);
- for (i=0;i<maps_size;i++)
+ for (i=0;i<maps_size;i++)
gaim_upnp_change_port_mapping(ectx,
cfg,
NO,
maps[i].port,
- maps[i].proto);
+ maps[i].proto);
MUTEX_UNLOCK(lock);
}
@@ -125,11 +125,11 @@
unsigned int i;
MUTEX_LOCK(lock);
- for (i=0;i<maps_size;i++)
+ for (i=0;i<maps_size;i++)
if ( (0 == strcmp(maps[i].proto, protocol)) &&
(maps[i].port == port) )
break;
- if (i == maps_size) {
+ if (i == maps_size) {
/* new entry! */
GROW(maps,
maps_size,
@@ -150,7 +150,7 @@
/**
* Get the external IP address for the local machine.
*/
-UPnP_ServiceAPI *
+UPnP_ServiceAPI *
provide_module_upnp(CoreAPIForApplication * capi) {
static UPnP_ServiceAPI api;
@@ -181,12 +181,12 @@
if (cron == NULL)
return SYSERR; /* not loaded! */
- for (i=0;i<maps_size;i++)
+ for (i=0;i<maps_size;i++)
gaim_upnp_change_port_mapping(ectx,
cfg,
NO,
maps[i].port,
- maps[i].proto);
+ maps[i].proto);
cron_stop(cron);
cron_del_job(cron,
&discover,
Modified: GNUnet/src/transports/upnp/upnp.c
===================================================================
--- GNUnet/src/transports/upnp/upnp.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/upnp/upnp.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -107,7 +107,7 @@
} UPnPDiscoveryData;
static GaimUPnPControlInfo control_info = {
- GAIM_UPNP_STATUS_UNDISCOVERED,
+ GAIM_UPNP_STATUS_UNDISCOVERED,
NULL,
NULL,
"",
@@ -160,60 +160,60 @@
}
static int
-gaim_upnp_compare_device(const xmlnode* device,
+gaim_upnp_compare_device(const xmlnode* device,
const char* deviceType) {
xmlnode * deviceTypeNode = xmlnode_get_child(device, "deviceType");
char * tmp;
int ret;
-
- if (deviceTypeNode == NULL)
+
+ if (deviceTypeNode == NULL)
return FALSE;
tmp = xmlnode_get_data(deviceTypeNode);
ret = !strcasecmp(tmp, deviceType);
- FREE(tmp);
+ FREE(tmp);
return ret;
}
static int
-gaim_upnp_compare_service(const xmlnode* service,
+gaim_upnp_compare_service(const xmlnode* service,
const char* serviceType) {
xmlnode * serviceTypeNode;
char *tmp;
int ret;
-
- if (service == NULL)
+
+ if (service == NULL)
return FALSE;
serviceTypeNode = xmlnode_get_child(service, "serviceType");
- if(serviceTypeNode == NULL)
+ if(serviceTypeNode == NULL)
return FALSE;
tmp = xmlnode_get_data(serviceTypeNode);
ret = !strcasecmp(tmp, serviceType);
- FREE(tmp);
+ FREE(tmp);
return ret;
}
static char*
-gaim_upnp_parse_description_response(const char* httpResponse,
+gaim_upnp_parse_description_response(const char* httpResponse,
size_t len,
const char* httpURL,
const char* serviceType) {
char *xmlRoot, *baseURL, *controlURL, *service;
xmlnode *xmlRootNode, *serviceTypeNode, *controlURLNode, *baseURLNode;
char *tmp;
-
+
/* find the root of the xml document */
xmlRoot = g_strstr_len(httpResponse, len, "<root");
if (xmlRoot == NULL)
- return NULL;
- if (g_strstr_len(httpResponse, len, "</root") == NULL)
- return NULL;
+ return NULL;
+ if (g_strstr_len(httpResponse, len, "</root") == NULL)
+ return NULL;
/* create the xml root node */
xmlRootNode = xmlnode_from_str(xmlRoot,
len - (xmlRoot - httpResponse));
- if (xmlRootNode == NULL)
- return NULL;
-
+ if (xmlRootNode == NULL)
+ return NULL;
+
/* get the baseURL of the device */
baseURLNode = xmlnode_get_child(xmlRootNode, "URLBase");
if (baseURLNode != NULL) {
@@ -221,8 +221,8 @@
} else {
baseURL = STRDUP(httpURL);
}
-
- /* get the serviceType child that has the service type as its data */
+
+ /* get the serviceType child that has the service type as its data */
/* get urn:schemas-upnp-org:device:InternetGatewayDevice:1 and its
devicelist */
serviceTypeNode = xmlnode_get_child(xmlRootNode, "device");
while(!gaim_upnp_compare_device(serviceTypeNode,
@@ -241,7 +241,7 @@
xmlnode_free(xmlRootNode);
return NULL;
}
-
+
/* get urn:schemas-upnp-org:device:WANDevice:1 and its devicelist */
serviceTypeNode = xmlnode_get_child(serviceTypeNode, "device");
while(!gaim_upnp_compare_device(serviceTypeNode,
@@ -260,7 +260,7 @@
xmlnode_free(xmlRootNode);
return NULL;
}
-
+
/* get urn:schemas-upnp-org:device:WANConnectionDevice:1 and its servicelist
*/
serviceTypeNode = xmlnode_get_child(serviceTypeNode, "device");
while(serviceTypeNode && !gaim_upnp_compare_device(serviceTypeNode,
@@ -278,7 +278,7 @@
xmlnode_free(xmlRootNode);
return NULL;
}
-
+
/* get the serviceType variable passed to this function */
service = g_strdup_printf(SEARCH_REQUEST_DEVICE, serviceType);
serviceTypeNode = xmlnode_get_child(serviceTypeNode, "service");
@@ -286,14 +286,14 @@
serviceTypeNode != NULL) {
serviceTypeNode = xmlnode_get_next_twin(serviceTypeNode);
}
-
+
FREE(service);
if (serviceTypeNode == NULL) {
FREE(baseURL);
xmlnode_free(xmlRootNode);
return NULL;
}
-
+
/* get the controlURL of the service */
if((controlURLNode = xmlnode_get_child(serviceTypeNode,
"controlURL")) == NULL) {
@@ -301,7 +301,7 @@
xmlnode_free(xmlRootNode);
return NULL;
}
-
+
tmp = xmlnode_get_data(controlURLNode);
if(baseURL && !gaim_str_has_prefix(tmp, "http://") &&
!gaim_str_has_prefix(tmp, "HTTP://")) {
@@ -328,7 +328,7 @@
}
FREE(baseURL);
xmlnode_free(xmlRootNode);
-
+
return controlURL;
}
@@ -366,7 +366,7 @@
static int
gaim_upnp_generate_action_message_and_send(const char * proxy,
const char* actionName,
- const char* actionParams,
+ const char* actionParams,
GaimUtilFetchUrlCallback cb,
void * cb_data) {
CURL * curl;
@@ -377,16 +377,16 @@
struct curl_slist * headers = NULL;
GE_ASSERT(NULL, cb != NULL);
- if (0 != curl_global_init(CURL_GLOBAL_WIN32))
+ if (0 != curl_global_init(CURL_GLOBAL_WIN32))
return SYSERR;
- /* set the soap message */
- soapMessage = g_strdup_printf(SOAP_ACTION,
+ /* set the soap message */
+ soapMessage = g_strdup_printf(SOAP_ACTION,
actionName,
- control_info.service_type,
- actionParams,
+ control_info.service_type,
+ actionParams,
actionName);
soapHeader = g_strdup_printf(HTTP_POST_SOAP_HEADER,
- control_info.service_type,
+ control_info.service_type,
actionName);
sizeHeader = g_strdup_printf(HTTP_POST_SIZE_HEADER,
strlen(soapMessage));
@@ -400,15 +400,15 @@
cb);
CURL_EASY_SETOPT(curl,
CURLOPT_WRITEDATA,
- cb_data);
+ cb_data);
CURL_EASY_SETOPT(curl,
CURLOPT_POST,
1);
- headers = curl_slist_append(headers,
+ headers = curl_slist_append(headers,
"CONTENT-TYPE: text/xml ; charset=\"utf-8\"");
- headers = curl_slist_append(headers,
+ headers = curl_slist_append(headers,
soapHeader);
- headers = curl_slist_append(headers,
+ headers = curl_slist_append(headers,
sizeHeader);
CURL_EASY_SETOPT(curl,
CURLOPT_HTTPHEADER,
@@ -446,9 +446,9 @@
static size_t
-looked_up_public_ip_cb(void *url_data,
+looked_up_public_ip_cb(void *url_data,
size_t size,
- size_t nmemb,
+ size_t nmemb,
void * user_data) {
UPnPDiscoveryData * dd = user_data;
size_t len = size * nmemb;
@@ -468,20 +468,20 @@
/* extract the ip, or see if there is an error */
if ((temp = g_strstr_len(dd->buf,
dd->buf_len,
- "<NewExternalIPAddress")) == NULL)
- return len;
- if (!(temp = g_strstr_len(temp,
- dd->buf_len - (temp - dd->buf), ">")))
+ "<NewExternalIPAddress")) == NULL)
return len;
- if (!(temp2 = g_strstr_len(temp,
- dd->buf_len - (temp - dd->buf), "<")))
+ if (!(temp = g_strstr_len(temp,
+ dd->buf_len - (temp - dd->buf), ">")))
return len;
- memset(control_info.publicip,
+ if (!(temp2 = g_strstr_len(temp,
+ dd->buf_len - (temp - dd->buf), "<")))
+ return len;
+ memset(control_info.publicip,
0,
sizeof(control_info.publicip));
if (temp2 - temp >= sizeof(control_info.publicip))
temp2 = temp + sizeof(control_info.publicip) - 1;
- memcpy(control_info.publicip,
+ memcpy(control_info.publicip,
temp + 1,
temp2 - (temp + 1));
GE_LOG(NULL,
@@ -493,9 +493,9 @@
static size_t
-ignore_response(void *url_data,
+ignore_response(void *url_data,
size_t size,
- size_t nmemb,
+ size_t nmemb,
void * user_data) {
return size * nmemb;
}
@@ -511,7 +511,7 @@
UPnPDiscoveryData * dd = user_data;
size_t len = size * nmemb;
char * control_url = NULL;
-
+
if (len + dd->buf_len > 1024 * 1024 * 4)
return len; /* refuse to process - too big! */
GROW(dd->buf,
@@ -538,8 +538,8 @@
UPnPDiscoveryData * dd) {
CURL * curl;
int ret;
-
- if (0 != curl_global_init(CURL_GLOBAL_WIN32))
+
+ if (0 != curl_global_init(CURL_GLOBAL_WIN32))
return SYSERR;
curl = curl_easy_init();
setup_curl(proxy, curl);
@@ -588,42 +588,42 @@
UPnPDiscoveryData dd;
memset(&dd,
- 0,
+ 0,
sizeof(UPnPDiscoveryData));
- if (control_info.status == GAIM_UPNP_STATUS_DISCOVERING)
+ if (control_info.status == GAIM_UPNP_STATUS_DISCOVERING)
return NO;
dd.sock = sock;
hp = gethostbyname(HTTPMU_HOST_ADDRESS);
if (hp == NULL) {
CLOSE(dd.sock);
- return SYSERR;
- }
+ return SYSERR;
+ }
memset(&server,
- 0,
+ 0,
sizeof(struct sockaddr));
server.sin_family = AF_INET;
memcpy(&server.sin_addr,
hp->h_addr_list[0],
hp->h_length);
- server.sin_port = htons(HTTPMU_HOST_PORT);
+ server.sin_port = htons(HTTPMU_HOST_PORT);
control_info.status = GAIM_UPNP_STATUS_DISCOVERING;
-
+
/* because we are sending over UDP, if there is a failure
we should retry the send NUM_UDP_ATTEMPTS times. Also,
try different requests for WANIPConnection and WANPPPConnection*/
for (retry_count=0;retry_count<NUM_UDP_ATTEMPTS;retry_count++) {
- sentSuccess = FALSE;
- if((retry_count % 2) == 0)
+ sentSuccess = FALSE;
+ if((retry_count % 2) == 0)
dd.service_type = WAN_IP_CONN_SERVICE;
- else
- dd.service_type = WAN_PPP_CONN_SERVICE;
- sendMessage = g_strdup_printf(SEARCH_REQUEST_STRING,
+ else
+ dd.service_type = WAN_PPP_CONN_SERVICE;
+ sendMessage = g_strdup_printf(SEARCH_REQUEST_STRING,
dd.service_type);
totalSize = strlen(sendMessage);
do {
if (SENDTO(dd.sock,
- sendMessage,
- totalSize,
+ sendMessage,
+ totalSize,
0,
(struct sockaddr*) &server,
sizeof(struct sockaddr_in)) == totalSize) {
@@ -632,19 +632,19 @@
}
} while ( ((errno == EINTR) || (errno == EAGAIN)) &&
(GNUNET_SHUTDOWN_TEST() == NO));
- FREE(sendMessage);
- if (sentSuccess)
+ FREE(sendMessage);
+ if (sentSuccess)
break;
}
- if (sentSuccess == FALSE)
- return SYSERR;
+ if (sentSuccess == FALSE)
+ return SYSERR;
/* try to read response */
do {
buf_len = recv(dd.sock,
buf,
- sizeof(buf) - 1,
- 0);
+ sizeof(buf) - 1,
+ 0);
if (buf_len > 0) {
buf[buf_len] = '\0';
break;
@@ -655,40 +655,40 @@
(GNUNET_SHUTDOWN_TEST() == NO) );
/* parse the response, and see if it was a success */
- if (g_strstr_len(buf, buf_len, HTTP_OK) == NULL)
- return SYSERR;
- if ( (startDescURL = g_strstr_len(buf, buf_len, "http://")) == NULL)
- return SYSERR;
-
+ if (g_strstr_len(buf, buf_len, HTTP_OK) == NULL)
+ return SYSERR;
+ if ( (startDescURL = g_strstr_len(buf, buf_len, "http://")) == NULL)
+ return SYSERR;
+
endDescURL = g_strstr_len(startDescURL,
buf_len - (startDescURL - buf),
"\r");
- if (endDescURL == NULL)
+ if (endDescURL == NULL)
endDescURL = g_strstr_len(startDescURL,
buf_len - (startDescURL - buf), "\n");
- if(endDescURL == NULL)
- return SYSERR;
- if (endDescURL == startDescURL)
- return SYSERR;
+ if(endDescURL == NULL)
+ return SYSERR;
+ if (endDescURL == startDescURL)
+ return SYSERR;
dd.full_url = STRNDUP(startDescURL,
- endDescURL - startDescURL);
- proxy = NULL;
+ endDescURL - startDescURL);
+ proxy = NULL;
GC_get_configuration_value_string(cfg,
"GNUNETD",
"HTTP-PROXY",
"",
&proxy);
ret = gaim_upnp_parse_description(proxy,
- &dd);
+ &dd);
FREE(dd.full_url);
GROW(dd.buf,
dd.buf_len,
0);
if (ret == OK) {
ret = gaim_upnp_generate_action_message_and_send(proxy,
- "GetExternalIPAddress",
+ "GetExternalIPAddress",
"",
- looked_up_public_ip_cb,
+ looked_up_public_ip_cb,
&dd);
GROW(dd.buf,
dd.buf_len,
@@ -711,15 +711,15 @@
gaim_upnp_change_port_mapping(struct GE_Context * ectx,
struct GC_Configuration * cfg,
int do_add,
- unsigned short portmap,
+ unsigned short portmap,
const char* protocol) {
const char * action_name;
char * action_params;
char * internal_ip;
char * proxy;
int ret;
-
- if (control_info.status != GAIM_UPNP_STATUS_DISCOVERED)
+
+ if (control_info.status != GAIM_UPNP_STATUS_DISCOVERED)
return NO;
if (do_add) {
internal_ip = gaim_upnp_get_internal_ip(cfg,
@@ -731,7 +731,7 @@
}
action_name = "AddPortMapping";
action_params = g_strdup_printf(ADD_PORT_MAPPING_PARAMS,
- portmap,
+ portmap,
protocol,
portmap,
internal_ip);
@@ -739,10 +739,10 @@
} else {
action_name = "DeletePortMapping";
action_params = g_strdup_printf(DELETE_PORT_MAPPING_PARAMS,
- portmap,
+ portmap,
protocol);
- }
- proxy = NULL;
+ }
+ proxy = NULL;
GC_get_configuration_value_string(cfg,
"GNUNETD",
"HTTP-PROXY",
@@ -753,10 +753,10 @@
action_params,
&ignore_response,
NULL);
-
+
FREE(action_params);
FREE(proxy);
- return ret;
+ return ret;
}
/* end of upnp.c */
Modified: GNUnet/src/transports/upnp/upnptest.c
===================================================================
--- GNUnet/src/transports/upnp/upnptest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/transports/upnp/upnptest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -77,7 +77,7 @@
return 1;
}
for (i=0;i<10;i++) {
- if (GNUNET_SHUTDOWN_TEST() != NO)
+ if (GNUNET_SHUTDOWN_TEST() != NO)
break;
if (OK == upnp->get_ip(2086,
"TCP",
Modified: GNUnet/src/transports/upnp/util.c
===================================================================
--- GNUnet/src/transports/upnp/util.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/transports/upnp/util.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -28,17 +28,17 @@
/* Returns a NULL-terminated string after unescaping an entity
* (eg. &, < & etc.) starting at s. Returns NULL on failure.*/
static char *
-detect_entity(const char *text,
+detect_entity(const char *text,
int *length) {
const char *pln;
int len;
int pound;
-
+
if (!text || *text != '&')
return NULL;
-
+
#define IS_ENTITY(s) (!strncasecmp(text, s, (len = sizeof(s) - 1)))
-
+
if(IS_ENTITY("&"))
pln = "&";
else if(IS_ENTITY("<"))
@@ -73,13 +73,13 @@
if (text[len] == ';') len++;
} else
return NULL;
-
+
if (length)
*length = len;
return STRDUP(pln);
}
-char *
+char *
g_strdup_printf(const char * fmt,
...) {
size_t size;
@@ -105,7 +105,7 @@
while (*c) {
int len;
char *ent;
-
+
if ((ent = detect_entity(c, &len)) != NULL) {
app = g_strdup_printf("%s%s", ret, ent);
FREE(ret);
@@ -125,7 +125,7 @@
}
}
return ret;
- }
+ }
return NULL;
}
Modified: GNUnet/src/transports/upnp/xmlnode.c
===================================================================
--- GNUnet/src/transports/upnp/xmlnode.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/transports/upnp/xmlnode.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -103,11 +103,11 @@
}
static xmlnode*
-new_node(const char *name,
+new_node(const char *name,
XMLNodeType type,
void * user_data) {
xmlnode *node = MALLOC(sizeof(xmlnode));
-
+
node->name = name == NULL ? NULL : STRDUP(name);
node->type = type;
node->pool = user_data;
@@ -123,22 +123,22 @@
static xmlnode*
xmlnode_new(const char *name,
void * user_data) {
- g_return_val_if_fail(name != NULL, NULL);
- return new_node(name,
- XMLNODE_TYPE_TAG,
+ g_return_val_if_fail(name != NULL, NULL);
+ return new_node(name,
+ XMLNODE_TYPE_TAG,
user_data);
}
static void
-xmlnode_insert_child(xmlnode *parent,
+xmlnode_insert_child(xmlnode *parent,
xmlnode *child) {
g_return_if_fail(parent != NULL);
g_return_if_fail(child != NULL);
-
- child->parent = parent;
- if(parent->lastchild)
+
+ child->parent = parent;
+ if(parent->lastchild)
parent->lastchild->next = child;
- else
+ else
parent->child = child;
parent->lastchild = child;
}
@@ -148,40 +148,40 @@
const char *name,
void * user_data) {
xmlnode *node;
-
+
g_return_val_if_fail(parent != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
- node = new_node(name, XMLNODE_TYPE_TAG, user_data);
- xmlnode_insert_child(parent, node);
+ g_return_val_if_fail(name != NULL, NULL);
+ node = new_node(name, XMLNODE_TYPE_TAG, user_data);
+ xmlnode_insert_child(parent, node);
return node;
}
static void
-xmlnode_insert_data(xmlnode *node,
- const char *data,
- int size,
+xmlnode_insert_data(xmlnode *node,
+ const char *data,
+ int size,
void * user_data) {
xmlnode *child;
size_t real_size;
-
+
g_return_if_fail(node != NULL);
g_return_if_fail(data != NULL);
- g_return_if_fail(size != 0);
- real_size = size == -1 ? strlen(data) : size;
- child = new_node(NULL, XMLNODE_TYPE_DATA, user_data);
+ g_return_if_fail(size != 0);
+ real_size = size == -1 ? strlen(data) : size;
+ child = new_node(NULL, XMLNODE_TYPE_DATA, user_data);
child->data = g_memdup(data, real_size);
- child->data_sz = real_size;
+ child->data_sz = real_size;
xmlnode_insert_child(node, child);
}
static void
-xmlnode_remove_attrib(xmlnode *node,
+xmlnode_remove_attrib(xmlnode *node,
const char *attr) {
xmlnode *attr_node, *sibling = NULL;
-
+
g_return_if_fail(node != NULL);
g_return_if_fail(attr != NULL);
-
+
for(attr_node = node->child; attr_node; attr_node = attr_node->next) {
if(attr_node->type == XMLNODE_TYPE_ATTRIB &&
!strcmp(attr_node->name, attr)) {
@@ -201,30 +201,30 @@
}
static void
-xmlnode_set_attrib(xmlnode *node,
- const char *attr,
- const char *value,
+xmlnode_set_attrib(xmlnode *node,
+ const char *attr,
+ const char *value,
void * user_data) {
xmlnode *attrib_node;
g_return_if_fail(node != NULL);
g_return_if_fail(attr != NULL);
g_return_if_fail(value != NULL);
- xmlnode_remove_attrib(node, attr);
- attrib_node = new_node(attr, XMLNODE_TYPE_ATTRIB, user_data);
- attrib_node->data = STRDUP(value);
+ xmlnode_remove_attrib(node, attr);
+ attrib_node = new_node(attr, XMLNODE_TYPE_ATTRIB, user_data);
+ attrib_node->data = STRDUP(value);
xmlnode_insert_child(node, attrib_node);
}
-static void xmlnode_set_namespace(xmlnode *node,
+static void xmlnode_set_namespace(xmlnode *node,
const char *xmlns) {
- g_return_if_fail(node != NULL);
+ g_return_if_fail(node != NULL);
FREENONNULL(node->xmlns);
node->xmlns = STRDUP(xmlns);
}
static const char *xmlnode_get_namespace(xmlnode *node) {
- g_return_val_if_fail(node != NULL, NULL);
+ g_return_val_if_fail(node != NULL, NULL);
return node->xmlns;
}
@@ -234,7 +234,7 @@
xmlnode * x;
for (i=0;i<pool->pos;i++) {
- x = pool->nodes[i];
+ x = pool->nodes[i];
FREENONNULL(x->name);
FREENONNULL(x->data);
FREENONNULL(x->xmlns);
@@ -249,56 +249,56 @@
void
xmlnode_free(xmlnode *node) {
g_return_if_fail(node != NULL);
- if (node->free_pool != YES)
+ if (node->free_pool != YES)
return;
freePool(node->pool);
}
static xmlnode *
-xmlnode_get_child_with_namespace(const xmlnode *parent,
- const char *name,
+xmlnode_get_child_with_namespace(const xmlnode *parent,
+ const char *name,
const char *ns) {
xmlnode *x;
xmlnode *ret = NULL;
char *parent_name;
char *child_name;
-
+
if (parent == NULL)
return NULL;
if (name == NULL)
return NULL;
-
+
parent_name = STRDUP(name);
child_name = strstr(parent_name, "/");
if (child_name != NULL) {
child_name[0] = '\0';
child_name++;
- }
-
+ }
+
for(x = parent->child; x; x = x->next) {
const char *xmlns = NULL;
if(ns)
xmlns = xmlnode_get_namespace(x);
-
+
if(x->type == XMLNODE_TYPE_TAG && name && !strcmp(parent_name, x->name)
&& (!ns || (xmlns && !strcmp(ns, xmlns)))) {
ret = x;
break;
}
}
-
+
if (child_name && ret)
ret = xmlnode_get_child(ret, child_name);
-
+
FREE(parent_name);
return ret;
}
xmlnode*
-xmlnode_get_child(const xmlnode *parent,
+xmlnode_get_child(const xmlnode *parent,
const char *name) {
return xmlnode_get_child_with_namespace(parent,
- name,
+ name,
NULL);
}
@@ -306,45 +306,45 @@
xmlnode_get_data(xmlnode *node) {
char *str = NULL;
xmlnode *c;
-
+
if (node == NULL)
- return NULL;
+ return NULL;
for(c = node->child; c; c = c->next) {
if(c->type == XMLNODE_TYPE_DATA) {
if(!str)
str = STRDUP("");
str = g_string_append_len(str, c->data, c->data_sz);
}
- }
+ }
if (str == NULL)
return NULL;
-
+
return str;
}
static void
xmlnode_parser_element_start_libxml(void *user_data,
- const xmlChar *element_name,
- const xmlChar *prefix,
+ const xmlChar *element_name,
+ const xmlChar *prefix,
const xmlChar *xmlns,
int nb_namespaces,
const xmlChar **namespaces,
- int nb_attributes,
- int nb_defaulted,
+ int nb_attributes,
+ int nb_defaulted,
const xmlChar **attributes) {
XMLNodePool *xpd = user_data;
xmlnode *node;
int i;
-
- if (!element_name)
+
+ if (!element_name)
return;
if (xpd->current)
node = xmlnode_new_child(xpd->current, (const char*) element_name,
user_data);
else
node = xmlnode_new((const char *) element_name, user_data);
-
+
xmlnode_set_namespace(node, (const char *) xmlns);
-
+
for(i=0; i < nb_attributes * 5; i+=5) {
char *txt;
int attrib_len = attributes[i+4] - attributes[i+3];
@@ -356,19 +356,19 @@
FREE(txt);
xmlnode_set_attrib(node, (const char*) attributes[i], attrib, user_data);
FREE(attrib);
- }
+ }
xpd->current = node;
}
static void
-xmlnode_parser_element_end_libxml(void *user_data,
+xmlnode_parser_element_end_libxml(void *user_data,
const xmlChar *element_name,
const xmlChar *prefix,
const xmlChar *xmlns) {
XMLNodePool *xpd = user_data;
-
+
if(!element_name || !xpd->current)
- return;
+ return;
if(xpd->current->parent) {
if(!xmlStrcmp((xmlChar*) xpd->current->name, element_name))
xpd->current = xpd->current->parent;
@@ -376,16 +376,16 @@
}
static void
-xmlnode_parser_element_text_libxml(void *user_data,
- const xmlChar *text,
+xmlnode_parser_element_text_libxml(void *user_data,
+ const xmlChar *text,
int text_len) {
XMLNodePool *xpd = user_data;
-
+
if (!xpd->current || !text || !text_len)
- return;
- xmlnode_insert_data(xpd->current,
+ return;
+ xmlnode_insert_data(xpd->current,
(const char*) text,
- text_len,
+ text_len,
user_data);
}
@@ -430,17 +430,17 @@
XMLNodePool *xpd;
xmlnode *ret;
size_t real_size;
-
+
g_return_val_if_fail(str != NULL, NULL);
-
+
real_size = size < 0 ? strlen(str) : size;
- xpd = MALLOC(sizeof(XMLNodePool));
- memset(xpd,
+ xpd = MALLOC(sizeof(XMLNodePool));
+ memset(xpd,
0,
sizeof(XMLNodePool));
- if (xmlSAXUserParseMemory(&xmlnode_parser_libxml,
- xpd,
- str,
+ if (xmlSAXUserParseMemory(&xmlnode_parser_libxml,
+ xpd,
+ str,
real_size) < 0) {
freePool(xpd);
return NULL;
@@ -454,18 +454,18 @@
xmlnode_get_next_twin(xmlnode *node) {
xmlnode *sibling;
const char *ns = xmlnode_get_namespace(node);
-
+
g_return_val_if_fail(node != NULL, NULL);
g_return_val_if_fail(node->type == XMLNODE_TYPE_TAG, NULL);
-
+
for(sibling = node->next; sibling; sibling = sibling->next) {
const char *xmlns = NULL;
if(ns)
xmlns = xmlnode_get_namespace(sibling);
-
+
if(sibling->type == XMLNODE_TYPE_TAG && !strcmp(node->name, sibling->name)
&&
(!ns || (xmlns && !strcmp(ns, xmlns))))
return sibling;
- }
+ }
return NULL;
}
Modified: GNUnet/src/transports/upnp/xmlnode.h
===================================================================
--- GNUnet/src/transports/upnp/xmlnode.h 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/transports/upnp/xmlnode.h 2007-06-08 06:18:58 UTC (rev
4944)
@@ -43,7 +43,7 @@
*
* @return The child or NULL.
*/
-xmlnode * xmlnode_get_child(const xmlnode *parent,
+xmlnode * xmlnode_get_child(const xmlnode *parent,
const char *name);
/**
@@ -76,7 +76,7 @@
*
* @return The new node.
*/
-xmlnode *xmlnode_from_str(const char *str,
+xmlnode *xmlnode_from_str(const char *str,
int size);
/**
Modified: GNUnet/src/util/boot/startup.c
===================================================================
--- GNUnet/src/util/boot/startup.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/boot/startup.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -112,8 +112,8 @@
FREE(user_log_level);
if (all != 0) {
nctx = GE_create_context_logfile(NULL,
- all
- | GE_ADMIN
+ all
+ | GE_ADMIN
| GE_BULK
| GE_IMMEDIATE,
admin_log_file,
@@ -189,13 +189,13 @@
argv);
if (i == -1)
return -1;
- if ( (YES != disk_file_test(*ectx,
+ if ( (YES != disk_file_test(*ectx,
*cfgFileName)) &&
(! is_daemon) ) {
char * run;
char * bindir;
size_t max;
-
+
bindir = os_get_installation_path(IPK_BINDIR);
max = 128 + strlen(*cfgFileName) + strlen(bindir);
run = MALLOC(max);
@@ -206,14 +206,14 @@
*cfgFileName);
FREE(bindir);
ret = system(run);
- if (0 != ret)
+ if (0 != ret)
GE_LOG(*ectx,
GE_ERROR | GE_USER | GE_IMMEDIATE,
_("Failed to run %s: %s %d\n"),
run,
strerror(errno),
WEXITSTATUS(ret));
- FREE(run);
+ FREE(run);
}
if (0 != GC_parse_configuration(*cfg,
*cfgFileName))
Modified: GNUnet/src/util/containers/hashtabletest.c
===================================================================
--- GNUnet/src/util/containers/hashtabletest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/util/containers/hashtabletest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -79,7 +79,7 @@
if (HT_CONTAINS_KEY(ht, "Spain") != NO)
{
puts("ht_remove failed!\n");
- ht_destroy(ht);
+ ht_destroy(ht);
return 1;
}
Modified: GNUnet/src/util/cron/cron.c
===================================================================
--- GNUnet/src/util/cron/cron.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/cron/cron.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -521,7 +521,7 @@
data);
}
/* run */
-#if DEBUG_CRON
+#if DEBUG_CRON
GE_LOG(cron->ectx,
GE_STATUS | GE_DEVELOPER | GE_BULK,
"running job %p-%p\n",
@@ -530,13 +530,13 @@
#endif
method(data);
MUTEX_LOCK(cron->deltaListLock_);
- cron->runningJob_ = NULL;
-#if DEBUG_CRON
+ cron->runningJob_ = NULL;
+#if DEBUG_CRON
GE_LOG(cron->ectx,
GE_STATUS | GE_DEVELOPER | GE_BULK,
"job %p-%p done\n",
method,
- data);
+ data);
#endif
}
Modified: GNUnet/src/util/crypto/hashingtest.c
===================================================================
--- GNUnet/src/util/crypto/hashingtest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/util/crypto/hashingtest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -33,16 +33,16 @@
HashCode512 h2;
EncName enc;
- memset(&h1,
- number,
+ memset(&h1,
+ number,
sizeof(HashCode512));
hash2enc(&h1, &enc);
if (OK != enc2hash((char*)&enc, &h2)) {
printf("enc2hash failed!\n");
return 1;
}
- if (! equalsHashCode512(&h1, &h2))
- return 1;
+ if (! equalsHashCode512(&h1, &h2))
+ return 1;
return 0;
}
Modified: GNUnet/src/util/crypto/hashperf.c
===================================================================
--- GNUnet/src/util/crypto/hashperf.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/crypto/hashperf.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -39,10 +39,10 @@
memset(buf, 1, 1024 * 64);
hash("foo", 3, &hc1);
for (i=0;i<1024;i++) {
- hash(&hc1,
+ hash(&hc1,
sizeof(HashCode512),
&hc2);
- hash(&hc2,
+ hash(&hc2,
sizeof(HashCode512),
&hc1);
hash(buf,
Modified: GNUnet/src/util/crypto/locking_gcrypt.c
===================================================================
--- GNUnet/src/util/crypto/locking_gcrypt.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/util/crypto/locking_gcrypt.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -33,7 +33,7 @@
* Should we use a lock to avoid concurrent accesses
* to gcrypt or should we tell gcrypt that we use
* pthreads?
- */
+ */
#define USE_LOCK NO
#if USE_LOCK
Modified: GNUnet/src/util/disk/storage.c
===================================================================
--- GNUnet/src/util/disk/storage.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/disk/storage.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -531,7 +531,7 @@
}
while ((finfo = readdir(dinfo)) != NULL) {
if ( (0 == strcmp(finfo->d_name, ".")) ||
- (0 == strcmp(finfo->d_name, "..")) )
+ (0 == strcmp(finfo->d_name, "..")) )
continue;
if (callback != NULL) {
if (OK != callback(finfo->d_name,
@@ -585,7 +585,7 @@
const char * fileName) {
struct stat istat;
- if (0 != STAT(fileName, &istat))
+ if (0 != STAT(fileName, &istat))
return NO; /* file may not exist... */
if (UNLINK(fileName) == 0)
return OK;
Modified: GNUnet/src/util/error/error.c
===================================================================
--- GNUnet/src/util/error/error.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/error/error.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -83,7 +83,7 @@
( ((kind & (GE_IMMEDIATE | GE_BULK)) == 0) ||
((kind & (GE_FATAL | GE_ERROR | GE_WARNING)) == 0) ) )
return;
-
+
#ifdef WINDOWS
/* Most tools disband the console window early in the initialization
process, so we have to create a new one if we're logging to the
@@ -95,7 +95,7 @@
fprintf(stderr, "%s", _("Error log:\n"));
}
#endif
-
+
va_start(va, message);
size = VSNPRINTF(NULL, 0, message, va) + 1;
va_end(va);
Modified: GNUnet/src/util/network/ip.c
===================================================================
--- GNUnet/src/util/network/ip.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/network/ip.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -91,8 +91,8 @@
ifa_ptr = ifa_first;
for (ifa_ptr = ifa_first; ifa_ptr != NULL; ifa_ptr = ifa_ptr->ifa_next) {
- if (ifa_ptr->ifa_name != NULL &&
- ifa_ptr->ifa_addr != NULL &&
+ if (ifa_ptr->ifa_name != NULL &&
+ ifa_ptr->ifa_addr != NULL &&
(ifa_ptr->ifa_flags & IFF_UP) != 0) {
if (strcmp(interfaces, (char *)ifa_ptr->ifa_name) != 0)
continue;
@@ -385,7 +385,7 @@
#endif
#if HAVE_GETIFADDRS && HAVE_FREEIFADDRS
if (retval == SYSERR)
- if (OK == getAddressFromGetIfAddrs(cfg,
+ if (OK == getAddressFromGetIfAddrs(cfg,
ectx,
&address))
retval = OK;
@@ -397,7 +397,7 @@
return NULL;
SNPRINTF(buf,
64,
- "%u.%u.%u.%u",
+ "%u.%u.%u.%u",
PRIP(ntohl(*(int*)&address)));
if (addr != NULL)
*addr = address;
Modified: GNUnet/src/util/network/select.c
===================================================================
--- GNUnet/src/util/network/select.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/network/select.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -619,7 +619,7 @@
FIONREAD,
&pending);
#endif
- if ( (error != 0) ||
+ if ( (error != 0) ||
(optlen != sizeof(pending)) ) {
GE_LOG_STRERROR(sh->ectx,
GE_ERROR | GE_ADMIN | GE_BULK,
@@ -633,9 +633,9 @@
sh,
pending);
#endif
- GE_ASSERT(sh->ectx,
+ GE_ASSERT(sh->ectx,
pending >= 0);
- if (pending >= 65536)
+ if (pending >= 65536)
pending = 65536;
if (pending == 0) {
/* maybe empty UDP packet was sent (see report on bug-gnunet,
@@ -807,7 +807,7 @@
* queueing messages (in bytes)
* @return NULL on error
*/
-SelectHandle *
+SelectHandle *
select_create(const char * description,
int is_udp,
struct GE_Context * ectx,
@@ -825,7 +825,7 @@
SelectHandle * sh;
if ( (is_udp == NO) &&
- (sock != -1) &&
+ (sock != -1) &&
(0 != LISTEN(sock, 5)) ) {
GE_LOG_STRERROR(ectx,
GE_ERROR | GE_USER | GE_IMMEDIATE,
@@ -1007,7 +1007,7 @@
(newBufferSize > sh->memory_quota) &&
(force == NO) )
newBufferSize = sh->memory_quota;
- GE_ASSERT(NULL,
+ GE_ASSERT(NULL,
newBufferSize >= len + session->wapos - session->wspos);
newBuffer = MALLOC(newBufferSize);
memcpy(newBuffer,
@@ -1024,7 +1024,7 @@
session->wapos + len <= session->wsize);
memcpy(&session->wbuff[session->wapos],
msg,
- len);
+ len);
session->wapos += len;
MUTEX_UNLOCK(sh->lock);
if (fresh_write)
Modified: GNUnet/src/util/network/selecttest.c
===================================================================
--- GNUnet/src/util/network/selecttest.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/util/network/selecttest.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -31,7 +31,7 @@
/**
* With sleeping, the kbps throughput is kind-of meaningless;
* without sleeping, the simulation is not as real-world
- * and performance is still erratic due to the sender
+ * and performance is still erratic due to the sender
* doing busy-waiting (and thus possibly burning CPU).
*/
#define DO_SLEEP YES
@@ -41,7 +41,7 @@
* this kills part of the test (proper select buffer
* management) and is not always portable, it can be
* useful to show the theoretical performance
- * (on my system about 100 mbps).
+ * (on my system about 100 mbps).
*/
#define DO_YIELD NO
@@ -85,7 +85,7 @@
static int sleeper;
char * expect;
unsigned short size;
-
+
size = ntohs(msg->size);
throughput += size;
expect = MALLOC(size);
@@ -135,9 +135,9 @@
struct SelectHandle * sh,
struct SocketHandle * sock,
const void * addr,
- unsigned int addr_len) {
+ unsigned int addr_len) {
static int ret_addr;
-
+
GE_BREAK(NULL, in == NULL);
in = sock;
return &ret_addr; /* dummy value for accept */
@@ -172,7 +172,7 @@
MESSAGE_HEADER * h;
cron_t start;
- listen_sock = SOCKET(PF_INET,
+ listen_sock = SOCKET(PF_INET,
SOCK_STREAM,
6); /* 6: TCP */
if (listen_sock == -1) {
@@ -217,7 +217,7 @@
NULL,
128 * 1024); /* memory quota */
- write_sock = SOCKET(PF_INET,
+ write_sock = SOCKET(PF_INET,
SOCK_STREAM,
6);
@@ -238,16 +238,16 @@
}
out = socket_create(NULL,
NULL,
- write_sock);
+ write_sock);
if (-1 == socket_set_blocking(out, NO)) {
socket_destroy(out);
select_destroy(sh);
return 1;
}
msg = 0;
- m = MALLOC(65536);
+ m = MALLOC(65536);
h = (MESSAGE_HEADER*) m;
- select_connect(sh,
+ select_connect(sh,
out,
NULL);
start = get_time();
Modified: GNUnet/src/util/network_client/tcpio.c
===================================================================
--- GNUnet/src/util/network_client/tcpio.c 2007-06-08 06:18:08 UTC (rev
4943)
+++ GNUnet/src/util/network_client/tcpio.c 2007-06-08 06:18:58 UTC (rev
4944)
@@ -82,7 +82,7 @@
char * res;
char * pos;
unsigned int port;
-
+
res = NULL;
if (-1 == GC_get_configuration_value_string(cfg,
"NETWORK",
@@ -118,12 +118,12 @@
*
* @return the name of the host, NULL on error
*/
-static char *
+static char *
getGNUnetdHost(struct GE_Context * ectx,
struct GC_Configuration * cfg) {
char * res;
char * pos;
-
+
res = NULL;
if (-1 == GC_get_configuration_value_string(cfg,
"NETWORK",
@@ -365,9 +365,9 @@
MUTEX_LOCK(sock->destroylock);
MUTEX_LOCK(sock->writelock);
- if (SYSERR == connection_ensure_connected(sock)) {
+ if (SYSERR == connection_ensure_connected(sock)) {
MUTEX_UNLOCK(sock->writelock);
- MUTEX_UNLOCK(sock->destroylock);
+ MUTEX_UNLOCK(sock->destroylock);
return SYSERR;
}
MUTEX_UNLOCK(sock->destroylock);
Modified: GNUnet/src/util/os/console.c
===================================================================
--- GNUnet/src/util/os/console.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/console.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -35,10 +35,10 @@
#include "platform.h"
-static char *
+static char *
getPIDFile(struct GC_Configuration * cfg) {
char * pif;
-
+
if (0 != GC_get_configuration_value_filename(cfg,
"GNUNETD",
"PIDFILE",
@@ -81,9 +81,9 @@
/* we get to create a directory -- and claim it
as ours! */
disk_directory_create(ectx, rdir);
- if (strlen(user))
+ if (strlen(user))
os_change_owner(ectx,
- rdir,
+ rdir,
user);
}
if (0 != ACCESS(rdir, W_OK | X_OK)) {
@@ -108,7 +108,7 @@
}
if (0 > FPRINTF(pidfd,
"%u",
- pid))
+ pid))
GE_LOG_STRERROR_FILE(ectx,
GE_WARNING | GE_ADMIN | GE_BULK,
"fprintf",
@@ -118,11 +118,11 @@
GE_WARNING | GE_ADMIN | GE_BULK,
"fclose",
pif);
- if (strlen(user))
+ if (strlen(user))
os_change_owner(ectx,
- pif,
+ pif,
user);
- FREE(user);
+ FREE(user);
FREE(pif);
return OK;
}
@@ -195,7 +195,7 @@
}
fflush(stdout);
if (ok == OK) {
- os_write_pid_file(ectx,
+ os_write_pid_file(ectx,
cfg,
pid);
exit(0);
Modified: GNUnet/src/util/os/cpustatus.c
===================================================================
--- GNUnet/src/util/os/cpustatus.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/cpustatus.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -69,7 +69,7 @@
/**
* Current CPU load, as percentage of CPU cycles not idle or
* blocked on IO.
- */
+ */
static int currentCPULoad;
static int agedCPULoad = -1;
@@ -89,7 +89,7 @@
kern_return_t kret;
int i,j;
- kret = host_processor_info(mach_host_self(),
+ kret = host_processor_info(mach_host_self(),
PROCESSOR_CPU_LOAD_INFO,
&cpu_count,
(processor_info_array_t *)&cpu_load,
@@ -412,7 +412,7 @@
dLastKernel = dKernel;
dLastIdle = dIdle;
dLastUser = dUser;
-
+
currentIOLoad = -1; /* FIXME */
return OK;
} else {
@@ -476,7 +476,7 @@
&dwDataSize);
RegCloseKey(hKey);
currentIOLoad = -1; /* FIXME! */
-
+
/* Stop query */
RegOpenKeyEx(HKEY_DYN_DATA,
"PerfStats\\StopStat",
Modified: GNUnet/src/util/os/daemon.c
===================================================================
--- GNUnet/src/util/os/daemon.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/daemon.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -40,7 +40,7 @@
const char * cfgFile,
int daemonize) {
pid_t pid;
-
+
#ifndef MINGW
pid = fork();
if (pid == 0)
Modified: GNUnet/src/util/os/osconfig.c
===================================================================
--- GNUnet/src/util/os/osconfig.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/osconfig.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -98,11 +98,11 @@
* @brief Set maximum number of open file descriptors
* @return OK on success, SYSERR on error
*/
-int os_set_fd_limit(struct GE_Context * ectx,
+int os_set_fd_limit(struct GE_Context * ectx,
int n) {
if (n == 0)
return OK;
-#if HAVE_SETRLIMIT
+#if HAVE_SETRLIMIT
struct rlimit rlim;
int ret;
Modified: GNUnet/src/util/os/semaphore.c
===================================================================
--- GNUnet/src/util/os/semaphore.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/semaphore.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -171,7 +171,7 @@
while ( (ret->internal == (void *) SEM_FAILED)
&& (errno == ENAMETOOLONG) ) {
char * halfBasename;
-
+
if (strlen(noslashBasename) < 4)
break; /* definitely OS error... */
/* FIXME: this might cause unintended mapping to same names */
Modified: GNUnet/src/util/os/semaphoretest.c
===================================================================
--- GNUnet/src/util/os/semaphoretest.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/semaphoretest.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -119,7 +119,7 @@
if (me == 0) {
exit(ret);
} else {
- GE_LOG(ectx,
+ GE_LOG(ectx,
GE_DEBUG | GE_REQUEST | GE_USER,
"waiting for other process to exit.\n");
if (-1 == waitpid(me, &j, 0))
Modified: GNUnet/src/util/os/statuscalls.c
===================================================================
--- GNUnet/src/util/os/statuscalls.c 2007-06-08 06:18:08 UTC (rev 4943)
+++ GNUnet/src/util/os/statuscalls.c 2007-06-08 06:18:58 UTC (rev 4944)
@@ -423,7 +423,7 @@
&monitor->upload_info.max);
monitor->last_ifc_update = get_time();
updateInterfaceTraffic(monitor);
- MUTEX_UNLOCK(monitor->statusMutex);
+ MUTEX_UNLOCK(monitor->statusMutex);
return 0;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r4944 - in GNUnet/src: applications/advertising applications/datastore applications/dht/module applications/dht/tools applications/dstore applications/fs applications/fs/ecrs applications/fs/fsui applications/fs/lib applications/fs/module applications/fs/namespace applications/fs/tools applications/fs/uritrack applications/gap applications/identity applications/pingpong applications/session applications/sqstore_mysql applications/sqstore_sqlite applications/stats applications/tbench applications/testing applications/topology_f2f applications/traffic applications/transport include server setup/gtk setup/lib setup/ncurses transports transports/upnp util/boot util/containers util/cron util/crypto util/disk util/error util/network util/network_client util/os,
gnunet <=