diff options
author | Angelo Mantellini <manangel@cisco.com> | 2019-02-10 13:34:22 +0100 |
---|---|---|
committer | Angelo Mantellini <manangel@cisco.com> | 2019-02-10 14:23:51 +0100 |
commit | 1ac41cb08281bf5460dfea5fc40ff6f8e14873a1 (patch) | |
tree | 3926983e45afa7e805cca1429fc3452c57a5b6c3 /hicn-light/src/strategies/loadBalancer.c | |
parent | 13ec18b4b3ec8455daad674a0c0e616885b83608 (diff) |
[HICN-49] Remove warnings hicn-light on windows
Change-Id: I106713c285ad5cc47cb5ae3aaf9c837685156e36
Signed-off-by: Angelo Mantellini <manangel@cisco.com>
Diffstat (limited to 'hicn-light/src/strategies/loadBalancer.c')
-rw-r--r-- | hicn-light/src/strategies/loadBalancer.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/hicn-light/src/strategies/loadBalancer.c b/hicn-light/src/strategies/loadBalancer.c index 14e907770..5be6a0182 100644 --- a/hicn-light/src/strategies/loadBalancer.c +++ b/hicn-light/src/strategies/loadBalancer.c @@ -78,7 +78,7 @@ StrategyImpl *strategyLoadBalancer_Create() { strategy->weights_sum = 0.0; strategy->strategy_state = parcHashMap_Create(); strategy->nexthops = numberSet_Create(); - srand(time(NULL)); + srand((unsigned int)time(NULL)); StrategyImpl *impl = parcMemory_AllocateAndClear(sizeof(StrategyImpl)); parcAssertNotNull(impl, "parcMemory_AllocateAndClear(%zu) returned NULL", @@ -170,7 +170,7 @@ static NumberSet *_strategyLoadBalancer_LookupNexthop( unsigned in_connection = message_GetIngressConnectionId(interestMessage); PARCUnsigned *in = parcUnsigned_Create(in_connection); - unsigned mapSize = parcHashMap_Size(lb->strategy_state); + unsigned mapSize = (unsigned)parcHashMap_Size(lb->strategy_state); NumberSet *outList = numberSet_Create(); if ((mapSize == 0) || @@ -211,7 +211,7 @@ static NumberSet *_strategyLoadBalancer_ReturnNexthops(StrategyImpl *strategy) { unsigned _strategyLoadBalancer_CountNexthops(StrategyImpl *strategy) { StrategyLoadBalancer *lb = (StrategyLoadBalancer *)strategy->context; - return numberSet_Length(lb->nexthops); + return (unsigned)numberSet_Length(lb->nexthops); } static void _strategyLoadBalancer_resetState(StrategyImpl *strategy) { |