mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-05-25 23:46:04 +08:00
[fix] call pprzlog_init if needed (and avoid segfault)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Hey Emacs, this is a -*- makefile -*-
|
||||
|
||||
sdlog_CFLAGS = -DDOWNLINK
|
||||
sdlog_CFLAGS = -DDOWNLINK -DUSE_PPRZLOG
|
||||
sdlog_srcs = subsystems/datalink/downlink.c subsystems/datalink/pprzlog_transport.c
|
||||
|
||||
ap.CFLAGS += $(sdlog_CFLAGS)
|
||||
|
||||
@@ -75,6 +75,10 @@ void downlink_init(void)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if USE_PPRZLOG
|
||||
pprzlog_transport_init();
|
||||
#endif
|
||||
|
||||
#if SITL
|
||||
ivy_transport_init();
|
||||
#endif
|
||||
|
||||
@@ -41,5 +41,8 @@ struct pprzlog_transport {
|
||||
|
||||
extern struct pprzlog_transport pprzlog_tp;
|
||||
|
||||
// Init function
|
||||
extern void pprzlog_transport_init(void);
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user