From b0c9c185f38c6bfc41a1d60e60aac1f7e79429dc Mon Sep 17 00:00:00 2001
From: gcontini <1121667+gcontini@users.noreply.github.com>
Date: 周日, 01 12月 2019 14:24:31 +0800
Subject: [PATCH] fix mingw

---
 src/library/licensecc.cpp |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/library/licensecc.cpp b/src/library/licensecc.cpp
index fe1b3a7..dfce497 100644
--- a/src/library/licensecc.cpp
+++ b/src/library/licensecc.cpp
@@ -24,13 +24,13 @@
 
 static void mergeLicenses(const vector<LicenseInfo>& licenses, LicenseInfo* license_out) {
 	if (license_out != nullptr) {
-		int days_left = -1;
+		int days_left = INT_MIN;
 		for (auto it = licenses.begin(); it != licenses.end(); it++) {
 			// choose the license that expires later...
 			if (!it->has_expiry) {
 				*license_out = *it;
 				break;
-			} else if (days_left < it->days_left) {
+			} else if (days_left < (int)it->days_left) {
 				*license_out = *it;
 				days_left = it->days_left;
 			}
@@ -40,7 +40,7 @@
 
 EVENT_TYPE acquire_license(const CallerInformations* callerInformation, const LicenseLocation* licenseLocation,
 						   LicenseInfo* license_out) {
-	license::LicenseReader lr = license::LicenseReader(licenseLocation);
+	const license::LicenseReader lr = license::LicenseReader(licenseLocation);
 	vector<license::FullLicenseInfo> licenses;
 	string project;
 	if (callerInformation != nullptr && strlen(callerInformation->project_name) > 0) {

--
Gitblit v1.9.1