Skip to content
Snippets Groups Projects
Commit ea11f188 authored by Hoop77's avatar Hoop77
Browse files

bugfix

parent 90be5046
No related merge requests found
......@@ -22,6 +22,9 @@ using InnerPlatoonDistance = float;
struct PlatoonConfig
{
PlatoonConfig() : platoonSpeed(0.0f), innerPlatoonDistance(0.0f)
{}
PlatoonConfig(PlatoonSpeed platoonSpeed, InnerPlatoonDistance innerPlatoonDistance)
: platoonSpeed(platoonSpeed), innerPlatoonDistance(innerPlatoonDistance)
{}
......@@ -35,7 +38,7 @@ bool operator==(const PlatoonConfig & lhs, const PlatoonConfig & rhs) noexcept;
bool operator!=(const PlatoonConfig & lhs, const PlatoonConfig & rhs) noexcept;
template<typename... Ts>
inline void log(const Ts &... args)
inline void log(const Ts & ... args)
{
#ifdef PLATOON_PROTOCOL_ENABLE_LOGGING
static std::mutex logMutex;
......
......@@ -70,7 +70,7 @@ protected:
RUNNING_PLATOON
};
static constexpr PlatoonConfig DEFAULT_PLATOON_CONFIG{0.0f, 0.0f};
static const PlatoonConfig DEFAULT_PLATOON_CONFIG;
const VehicleEndpoint ownEndpoint;
PlatoonId platoonId;
......
......@@ -12,7 +12,7 @@ using namespace platoonProtocol;
constexpr std::uint16_t Vehicle::UDP_PORT;
constexpr std::uint16_t Vehicle::TCP_PORT;
constexpr PlatoonConfig Vehicle::DEFAULT_PLATOON_CONFIG;
const PlatoonConfig Vehicle::DEFAULT_PLATOON_CONFIG{0.0f, 0.0f};
Vehicle::Vehicle(networking::Networking & net,
VehicleId ownVehicleId,
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment