[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r11959 - in gnunet/src: fs transport
From: |
gnunet |
Subject: |
[GNUnet-SVN] r11959 - in gnunet/src: fs transport |
Date: |
Fri, 25 Jun 2010 20:11:37 +0200 |
Author: grothoff
Date: 2010-06-25 20:11:37 +0200 (Fri, 25 Jun 2010)
New Revision: 11959
Modified:
gnunet/src/fs/gnunet-service-fs.c
gnunet/src/transport/gnunet-service-transport.c
gnunet/src/transport/plugin_transport_tcp.c
gnunet/src/transport/plugin_transport_udp.c
Log:
clenaer
Modified: gnunet/src/fs/gnunet-service-fs.c
===================================================================
--- gnunet/src/fs/gnunet-service-fs.c 2010-06-25 18:03:03 UTC (rev 11958)
+++ gnunet/src/fs/gnunet-service-fs.c 2010-06-25 18:11:37 UTC (rev 11959)
@@ -2672,8 +2672,15 @@
&prq);
cps = GNUNET_CONTAINER_multihashmap_get (connected_peers,
&other->hashPubKey);
- cps->inc_preference += CONTENT_BANDWIDTH_VALUE + 1000 * prq.priority;
- cps->trust_delta += prq.priority;
+ if (cps != NULL)
+ {
+ cps->inc_preference += CONTENT_BANDWIDTH_VALUE + 1000 * prq.priority;
+ cps->trust_delta += prq.priority;
+ }
+ else
+ {
+ GNUNET_break (0);
+ }
if (GNUNET_YES == active_migration)
{
#if DEBUG_FS
Modified: gnunet/src/transport/gnunet-service-transport.c
===================================================================
--- gnunet/src/transport/gnunet-service-transport.c 2010-06-25 18:03:03 UTC
(rev 11958)
+++ gnunet/src/transport/gnunet-service-transport.c 2010-06-25 18:11:37 UTC
(rev 11959)
@@ -57,7 +57,7 @@
* How many messages can we have pending for a given client process
* before we start to drop incoming messages? We typically should
* have only one client and so this would be the primary buffer for
- * messages, so the number should be chosen rather generously.
+ * messages, so the number should be chosen rather generously.
*
* The expectation here is that most of the time the queue is large
* enough so that a drop is virtually never required. Note that
@@ -3991,6 +3991,9 @@
gettext_noop ("# HELLOs received for validation"),
1,
GNUNET_NO);
+ GNUNET_CRYPTO_hash (&publicKey,
+ sizeof (struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded),
+ &target.hashPubKey);
/* first, check if load is too high */
if (GNUNET_SCHEDULER_get_load (sched,
GNUNET_SCHEDULER_PRIORITY_BACKGROUND) >
MAX_HELLO_LOAD)
@@ -4019,9 +4022,6 @@
GNUNET_break_op (0);
return GNUNET_SYSERR;
}
- GNUNET_CRYPTO_hash (&publicKey,
- sizeof (struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded),
- &target.hashPubKey);
if (0 == memcmp (&my_identity,
&target,
sizeof (struct GNUNET_PeerIdentity)))
Modified: gnunet/src/transport/plugin_transport_tcp.c
===================================================================
--- gnunet/src/transport/plugin_transport_tcp.c 2010-06-25 18:03:03 UTC (rev
11958)
+++ gnunet/src/transport/plugin_transport_tcp.c 2010-06-25 18:11:37 UTC (rev
11959)
@@ -791,10 +791,12 @@
{
GNUNET_SCHEDULER_cancel (session->plugin->env->sched,
session->receive_delay_task);
- GNUNET_SERVER_receive_done (session->client,
- GNUNET_SYSERR);
+ if (session->client != NULL)
+ GNUNET_SERVER_receive_done (session->client,
+ GNUNET_SYSERR);
}
- GNUNET_SERVER_client_drop (session->client);
+ if (session->client != NULL)
+ GNUNET_SERVER_client_drop (session->client);
GNUNET_STATISTICS_update (session->plugin->env->stats,
gettext_noop ("# TCP sessions active"),
-1,
Modified: gnunet/src/transport/plugin_transport_udp.c
===================================================================
--- gnunet/src/transport/plugin_transport_udp.c 2010-06-25 18:03:03 UTC (rev
11958)
+++ gnunet/src/transport/plugin_transport_udp.c 2010-06-25 18:11:37 UTC (rev
11959)
@@ -603,6 +603,7 @@
else
{
GNUNET_break_op (0);
+ GNUNET_free (message);
return -1;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r11959 - in gnunet/src: fs transport,
gnunet <=