From f8fcd65bc4598ac150477f6caa64c617ec220982 Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Sat, 18 Nov 2017 21:26:04 +0100 Subject: Prevent signed/unsigned comparison warning Change an unsigned integer to a signed integer in profilewidget2.cpp, because commit 1f8506c changed the definition of duration_t from unsigned to signed. Since this value represents the number of seconds since a dive started, there is no possible chance of overflow problems. Signed-off-by: Berthold Stoeger --- profile-widget/profilewidget2.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'profile-widget/profilewidget2.cpp') diff --git a/profile-widget/profilewidget2.cpp b/profile-widget/profilewidget2.cpp index cfe705f6f..e88fa0fc1 100644 --- a/profile-widget/profilewidget2.cpp +++ b/profile-widget/profilewidget2.cpp @@ -1592,7 +1592,7 @@ void ProfileWidget2::changeGas() qreal sec_val = timeAxis->valueAt(scenePos); // no gas changes before the dive starts - unsigned int seconds = (sec_val < 0.0) ? 0 : (unsigned int)sec_val; + int seconds = (sec_val < 0.0) ? 0 : (int)sec_val; // if there is a gas change at this time stamp, remove it before adding the new one struct event *gasChangeEvent = current_dc->events; -- cgit v1.2.3-70-g09d2