[Kea-users] [PATCH] gcc 6 compilation fix
Adam Majer
adamm at zombino.com
Mon Jul 25 21:01:27 UTC 2016
Hello,
Seems that Trac is causing issues trying to create issues ;)
Trac detected an internal error:
TypeError: must be convertible to a buffer, not Element
for GET: /newticket
Anyway, there is a small error in ISC KEA resulting in this
compilation error,
../../../../src/lib/dhcpsrv/pgsql_lease_mgr.cc:1693:56: error: no matching function for call to 'make_pair(uint32_t&, uint32_t&)'
return make_pair<uint32_t, uint32_t>(version, minor);
^
note: cannot convert 'version' (type 'uint32_t {aka unsigned int}') to type 'unsigned int&&'
return make_pair<uint32_t, uint32_t>(version, minor);
The error is caused by,
http://en.cppreference.com/w/cpp/utility/pair/make_pair
basically, by value is going away and you have to either transition to
type-deduced or use std::pair instead.
Index: isc-kea/src/lib/dhcpsrv/pgsql_lease_mgr.cc
===================================================================
--- isc-kea.orig/src/lib/dhcpsrv/pgsql_lease_mgr.cc
+++ isc-kea/src/lib/dhcpsrv/pgsql_lease_mgr.cc
@@ -1690,7 +1690,7 @@ PgSqlLeaseMgr::getVersion() const {
PQclear(r);
- return make_pair<uint32_t, uint32_t>(version, minor);
+ return std::pair<uint32_t, uint32_t>(version, minor);
}
void
More information about the Kea-users
mailing list