diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2010-10-27 11:31:32 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2010-10-27 11:31:32 +0000 |
commit | 666e63629635d497f469a14a5109575c5e38cf01 (patch) | |
tree | 4bd258275922393fa530994db9230c0c9303ddba /src | |
parent | 63f3303efa1023535a4290069751c2a20c6101e5 (diff) | |
download | gnunet-666e63629635d497f469a14a5109575c5e38cf01.tar.gz gnunet-666e63629635d497f469a14a5109575c5e38cf01.zip |
fixed problems with GNUNET_time_relative
Diffstat (limited to 'src')
-rw-r--r-- | src/dht/dht_api.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/dht/dht_api.c b/src/dht/dht_api.c index ea70b9000..d04e4d206 100644 --- a/src/dht/dht_api.c +++ b/src/dht/dht_api.c | |||
@@ -861,16 +861,14 @@ void | |||
861 | GNUNET_DHT_set_malicious_getter (struct GNUNET_DHT_Handle *handle, | 861 | GNUNET_DHT_set_malicious_getter (struct GNUNET_DHT_Handle *handle, |
862 | struct GNUNET_TIME_Relative frequency) | 862 | struct GNUNET_TIME_Relative frequency) |
863 | { | 863 | { |
864 | /* | 864 | if (frequency.rel_value > UINT16_MAX) |
865 | if (frequency.abs_value > UINT16_MAX) | ||
866 | { | 865 | { |
867 | GNUNET_break (0); | 866 | GNUNET_break (0); |
868 | return; | 867 | return; |
869 | } | 868 | } |
870 | send_control_message (handle, | 869 | send_control_message (handle, |
871 | GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_GET, frequency.abs_value, | 870 | GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_GET, frequency.rel_value, |
872 | NULL, NULL); | 871 | NULL, NULL); |
873 | */ | ||
874 | } | 872 | } |
875 | 873 | ||
876 | /** | 874 | /** |
@@ -884,17 +882,15 @@ void | |||
884 | GNUNET_DHT_set_malicious_putter (struct GNUNET_DHT_Handle *handle, | 882 | GNUNET_DHT_set_malicious_putter (struct GNUNET_DHT_Handle *handle, |
885 | struct GNUNET_TIME_Relative frequency) | 883 | struct GNUNET_TIME_Relative frequency) |
886 | { | 884 | { |
887 | /* | 885 | if (frequency.rel_value > UINT16_MAX) |
888 | if (frequency.abs_value > UINT16_MAX) | ||
889 | { | 886 | { |
890 | GNUNET_break (0); | 887 | GNUNET_break (0); |
891 | return; | 888 | return; |
892 | } | 889 | } |
893 | 890 | ||
894 | send_control_message (handle, | 891 | send_control_message (handle, |
895 | GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_PUT, frequency.abs_value, | 892 | GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_PUT, frequency.rel_value, |
896 | NULL, NULL); | 893 | NULL, NULL); |
897 | */ | ||
898 | } | 894 | } |
899 | 895 | ||
900 | 896 | ||