mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-11 02:13:57 -04:00
AP_Volz_Protocol: removed create() method for objects
See discussion here: https://github.com/ArduPilot/ardupilot/issues/7331 we were getting some uninitialised variables. While it only showed up in AP_SbusOut, it means we can't be sure it won't happen on other objects, so safest to remove the approach Thanks to assistance from Lucas, Peter and Francisco
This commit is contained in:
parent
d175fb2f18
commit
15026c6898
@ -50,22 +50,17 @@
|
|||||||
|
|
||||||
class AP_Volz_Protocol {
|
class AP_Volz_Protocol {
|
||||||
public:
|
public:
|
||||||
static const struct AP_Param::GroupInfo var_info[];
|
AP_Volz_Protocol();
|
||||||
|
|
||||||
static AP_Volz_Protocol create() {
|
|
||||||
return AP_Volz_Protocol{};
|
|
||||||
}
|
|
||||||
|
|
||||||
constexpr AP_Volz_Protocol(AP_Volz_Protocol &&other) = default;
|
|
||||||
|
|
||||||
/* Do not allow copies */
|
/* Do not allow copies */
|
||||||
AP_Volz_Protocol(const AP_Volz_Protocol &other) = delete;
|
AP_Volz_Protocol(const AP_Volz_Protocol &other) = delete;
|
||||||
AP_Volz_Protocol &operator=(const AP_Volz_Protocol&) = delete;
|
AP_Volz_Protocol &operator=(const AP_Volz_Protocol&) = delete;
|
||||||
|
|
||||||
|
static const struct AP_Param::GroupInfo var_info[];
|
||||||
|
|
||||||
void update();
|
void update();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
AP_Volz_Protocol();
|
|
||||||
AP_HAL::UARTDriver *port;
|
AP_HAL::UARTDriver *port;
|
||||||
|
|
||||||
void init(void);
|
void init(void);
|
||||||
|
Loading…
Reference in New Issue
Block a user