diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2014-07-17 09:47:51 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2014-07-17 09:47:51 +0000 |
commit | 615d5aef87f985e4c489fac6c6d6232d35f8b0c2 (patch) | |
tree | 82eb29b40821ee0a5405737ac2d9f0428c6c2619 /src/ats/plugin_ats_ril.c | |
parent | 6053799e5d05b8d5c6c664b66e48f367b3dd6578 (diff) | |
download | gnunet-615d5aef87f985e4c489fac6c6d6232d35f8b0c2.tar.gz gnunet-615d5aef87f985e4c489fac6c6d6232d35f8b0c2.zip |
do not use NBO internally
Diffstat (limited to 'src/ats/plugin_ats_ril.c')
-rw-r--r-- | src/ats/plugin_ats_ril.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/ats/plugin_ats_ril.c b/src/ats/plugin_ats_ril.c index 10650a5c4..4feb0fd9a 100644 --- a/src/ats/plugin_ats_ril.c +++ b/src/ats/plugin_ats_ril.c | |||
@@ -308,12 +308,12 @@ struct RIL_Peer_Agent | |||
308 | /** | 308 | /** |
309 | * Inbound bandwidth assigned by the agent | 309 | * Inbound bandwidth assigned by the agent |
310 | */ | 310 | */ |
311 | unsigned long long bw_in; | 311 | uint32_t bw_in; |
312 | 312 | ||
313 | /** | 313 | /** |
314 | * Outbound bandwidth assigned by the agent | 314 | * Outbound bandwidth assigned by the agent |
315 | */ | 315 | */ |
316 | unsigned long long bw_out; | 316 | uint32_t bw_out; |
317 | 317 | ||
318 | /** | 318 | /** |
319 | * Flag whether a suggestion has to be issued | 319 | * Flag whether a suggestion has to be issued |
@@ -346,22 +346,22 @@ struct RIL_Scope | |||
346 | /** | 346 | /** |
347 | * Total available inbound bandwidth | 347 | * Total available inbound bandwidth |
348 | */ | 348 | */ |
349 | unsigned long long bw_in_available; | 349 | uint32_t bw_in_available; |
350 | 350 | ||
351 | /** | 351 | /** |
352 | * Bandwidth inbound assigned in network after last step | 352 | * Bandwidth inbound assigned in network after last step |
353 | */ | 353 | */ |
354 | unsigned long long bw_in_assigned; | 354 | uint32_t bw_in_assigned; |
355 | 355 | ||
356 | /** | 356 | /** |
357 | * Bandwidth inbound actually utilized in the network | 357 | * Bandwidth inbound actually utilized in the network |
358 | */ | 358 | */ |
359 | unsigned long long bw_in_utilized; | 359 | uint32_t bw_in_utilized; |
360 | 360 | ||
361 | /** | 361 | /** |
362 | * Total available outbound bandwidth | 362 | * Total available outbound bandwidth |
363 | */ | 363 | */ |
364 | unsigned long long bw_out_available; | 364 | uint32_t bw_out_available; |
365 | 365 | ||
366 | /** | 366 | /** |
367 | * Bandwidth outbound assigned in network after last step | 367 | * Bandwidth outbound assigned in network after last step |
@@ -830,15 +830,15 @@ envi_set_active_suggestion (struct GAS_RIL_Handle *solver, | |||
830 | if (NULL != agent->address_inuse) | 830 | if (NULL != agent->address_inuse) |
831 | { | 831 | { |
832 | agent->address_inuse->active = GNUNET_NO; | 832 | agent->address_inuse->active = GNUNET_NO; |
833 | agent->address_inuse->assigned_bw_in.value__ = htonl (0); | 833 | agent->address_inuse->assigned_bw_in = 0; |
834 | agent->address_inuse->assigned_bw_out.value__ = htonl (0); | 834 | agent->address_inuse->assigned_bw_out = 0; |
835 | } | 835 | } |
836 | if (NULL != new_address) | 836 | if (NULL != new_address) |
837 | { | 837 | { |
838 | LOG(GNUNET_ERROR_TYPE_DEBUG, " set address active: %s\n", agent->is_active ? "yes" : "no"); | 838 | LOG(GNUNET_ERROR_TYPE_DEBUG, " set address active: %s\n", agent->is_active ? "yes" : "no"); |
839 | new_address->active = agent->is_active; | 839 | new_address->active = agent->is_active; |
840 | new_address->assigned_bw_in.value__ = htonl (agent->bw_in); | 840 | new_address->assigned_bw_in = agent->bw_in; |
841 | new_address->assigned_bw_out.value__ = htonl (agent->bw_out); | 841 | new_address->assigned_bw_out = agent->bw_out; |
842 | } | 842 | } |
843 | notify |= GNUNET_YES; | 843 | notify |= GNUNET_YES; |
844 | } | 844 | } |
@@ -856,13 +856,13 @@ envi_set_active_suggestion (struct GAS_RIL_Handle *solver, | |||
856 | if (agent->bw_in != new_bw_in) | 856 | if (agent->bw_in != new_bw_in) |
857 | { | 857 | { |
858 | agent->bw_in = new_bw_in; | 858 | agent->bw_in = new_bw_in; |
859 | new_address->assigned_bw_in.value__ = htonl (new_bw_in); | 859 | new_address->assigned_bw_in = new_bw_in; |
860 | notify |= GNUNET_YES; | 860 | notify |= GNUNET_YES; |
861 | } | 861 | } |
862 | if (agent->bw_out != new_bw_out) | 862 | if (agent->bw_out != new_bw_out) |
863 | { | 863 | { |
864 | agent->bw_out = new_bw_out; | 864 | agent->bw_out = new_bw_out; |
865 | new_address->assigned_bw_out.value__ = htonl (new_bw_out); | 865 | new_address->assigned_bw_out = new_bw_out; |
866 | notify |= GNUNET_YES; | 866 | notify |= GNUNET_YES; |
867 | } | 867 | } |
868 | } | 868 | } |
@@ -877,9 +877,9 @@ envi_set_active_suggestion (struct GAS_RIL_Handle *solver, | |||
877 | } | 877 | } |
878 | else if (agent->address_inuse) | 878 | else if (agent->address_inuse) |
879 | { | 879 | { |
880 | //disconnect case, no new address | 880 | /* disconnect case, no new address */ |
881 | GNUNET_assert(0 == ntohl (agent->address_inuse->assigned_bw_in.value__)); | 881 | GNUNET_assert(0 == agent->address_inuse->assigned_bw_in); |
882 | GNUNET_assert(0 == ntohl (agent->address_inuse->assigned_bw_out.value__)); | 882 | GNUNET_assert(0 == agent->address_inuse->assigned_bw_out); |
883 | agent->bw_in = 0; | 883 | agent->bw_in = 0; |
884 | agent->bw_out = 0; | 884 | agent->bw_out = 0; |
885 | 885 | ||