mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-11-08 19:31:36 +08:00
parameters: fix export shutdown locking
- in NuttX bchlib keeps a sector sized buffer that might not be written out to RAMTRON until the file is closed
This commit is contained in:
@@ -143,12 +143,6 @@ out:
|
||||
|
||||
size_t buf_size = bson_encoder_buf_size(&encoder);
|
||||
|
||||
int shutdown_lock_ret = px4_shutdown_lock();
|
||||
|
||||
if (shutdown_lock_ret) {
|
||||
PX4_ERR("px4_shutdown_lock() failed (%i)", shutdown_lock_ret);
|
||||
}
|
||||
|
||||
/* Get a buffer from the flash driver with enough space */
|
||||
|
||||
uint8_t *buffer;
|
||||
@@ -177,11 +171,6 @@ out:
|
||||
free(enc_buff);
|
||||
parameter_flashfs_free();
|
||||
}
|
||||
|
||||
if (shutdown_lock_ret == 0) {
|
||||
px4_shutdown_unlock();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user