From d00ebc22d25ef2d01c0f7146ce040c4fb9cc42b6 Mon Sep 17 00:00:00 2001 From: bebopagogo Date: Sun, 11 Sep 2022 14:27:21 -0400 Subject: [PATCH] fixed type casting issue with NormSenderNode::backoff_factor --- include/normNode.h | 2 +- makefiles/win32/normCast.vcxproj | 2 ++ src/common/normSession.cpp | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/include/normNode.h b/include/normNode.h index cb2355a..b678555 100755 --- a/include/normNode.h +++ b/include/normNode.h @@ -556,7 +556,7 @@ class NormSenderNode : public NormNode, public ProtoTree::Item UINT8 GetGrttQuantized() const {return grtt_quantized;} - UINT8 GetBackoffFactor() const + double GetBackoffFactor() const {return backoff_factor;} UINT8 GetGroupSizeQuantized() const {return gsize_quantized;} diff --git a/makefiles/win32/normCast.vcxproj b/makefiles/win32/normCast.vcxproj index cc58903..6aac276 100755 --- a/makefiles/win32/normCast.vcxproj +++ b/makefiles/win32/normCast.vcxproj @@ -249,6 +249,8 @@ + + diff --git a/src/common/normSession.cpp b/src/common/normSession.cpp index 294b501..6e90966 100755 --- a/src/common/normSession.cpp +++ b/src/common/normSession.cpp @@ -3157,7 +3157,7 @@ bool NormSession::InsertRemoteSender(NormSenderNode &sender) cmd.SetDestination(sender.GetAddress()); cmd.SetInstanceId(sender.GetInstanceId()); cmd.SetGrtt(sender.GetGrttQuantized()); - cmd.SetBackoffFactor(sender.GetBackoffFactor()); + cmd.SetBackoffFactor((UINT8)sender.GetBackoffFactor()); cmd.SetGroupSize(sender.GetGroupSizeQuantized()); cmd.SetCCSequence(sender.GetCCSequence()); // Adjust send time for any current hold time