diff options
author | Philipp Ringler <mail@philippmuenzel.de> | 2018-01-14 16:54:38 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-14 16:54:38 -0500 |
commit | af8fbb137d7601a565c036104d094cc819a72afd (patch) | |
tree | 83bfd70610210b3c68f7daaa9b912be5a05fee31 /x-plane-plugin | |
parent | 720b8d57847324a164e6f408d430bdc568b1b76c (diff) |
Fix XPluginEnable
This fixes the plugin loading in an undefined state. See https://forums.x-plane.org/index.php?/forums/topic/138529-psa-check-your-int-xpluginenable-function-definition/ for more information
Diffstat (limited to 'x-plane-plugin')
-rw-r--r-- | x-plane-plugin/plugin.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/x-plane-plugin/plugin.c b/x-plane-plugin/plugin.c index bc9b013d..1c41daf0 100644 --- a/x-plane-plugin/plugin.c +++ b/x-plane-plugin/plugin.c @@ -205,9 +205,10 @@ PLUGIN_API OTR_COMPAT_EXPORT void XPluginStop ( void ) { } } -PLUGIN_API OTR_COMPAT_EXPORT void XPluginEnable ( void ) { +PLUGIN_API OTR_COMPAT_EXPORT int XPluginEnable ( void ) { XPLMRegisterFlightLoopCallback(write_head_position, -1.0, NULL); track_disabled = 0; + return 1; } PLUGIN_API OTR_COMPAT_EXPORT void XPluginDisable ( void ) { |