diff mbox

opensm/osm_perfmgr_db.c: Fix output error due to possible 32bit int overflow

Message ID 1352399579.25353.106.camel@auk59.llnl.gov (mailing list archive)
State Accepted
Delegated to: Alex Netes
Headers show

Commit Message

Al Chu Nov. 8, 2012, 6:32 p.m. UTC
Signed-off-by: Albert L. Chu <chu11@llnl.gov>
---
 opensm/osm_perfmgr_db.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Alex Netes Jan. 20, 2013, 10:15 a.m. UTC | #1
Hi Albert,

On 10:32 Thu 08 Nov     , Albert Chu wrote:
> Signed-off-by: Albert L. Chu <chu11@llnl.gov>
> ---

Applied, thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/opensm/osm_perfmgr_db.c b/opensm/osm_perfmgr_db.c
index 98b587d..6095e1a 100644
--- a/opensm/osm_perfmgr_db.c
+++ b/opensm/osm_perfmgr_db.c
@@ -705,7 +705,7 @@  static void dump_hr_dc(FILE *fp, uint64_t val64, int data)
 	uint64_t tmp = val64;
 	float val = 0.0;
 	int ui = 0;
-	int div = 1;
+	uint64_t div = 1;
 
 	tmp /= 1024;
 	while (tmp) {