From 07db5a2242fdb83f1cafd36fb90d6fe76f3494e8 Mon Sep 17 00:00:00 2001 From: armink Date: Sat, 2 Oct 2021 16:57:37 +0800 Subject: [PATCH] [doc] Update the comment. --- docs/api.md | 2 +- docs/zh-cn/api.md | 2 +- inc/fdb_def.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/api.md b/docs/api.md index 5aef64a..8ba80b0 100644 --- a/docs/api.md +++ b/docs/api.md @@ -274,7 +274,7 @@ The supported command control words are as follows: #define FDB_TSDB_CTRL_GET_SEC_SIZE 0x01 /**< get sector size control command */ #define FDB_TSDB_CTRL_SET_LOCK 0x02 /**< set lock function control command */ #define FDB_TSDB_CTRL_SET_UNLOCK 0x03 /**< set unlock function control command */ -#define FDB_TSDB_CTRL_SET_ROLLOVER 0x04 /**< set rollover control command, this change MUST before database initialization */ +#define FDB_TSDB_CTRL_SET_ROLLOVER 0x04 /**< set rollover control command, this change MUST after database initialization */ #define FDB_TSDB_CTRL_GET_ROLLOVER 0x05 /**< get rollover control command */ #define FDB_TSDB_CTRL_GET_LAST_TIME 0x06 /**< get last save time control command */ #define FDB_TSDB_CTRL_SET_FILE_MODE 0x09 /**< set file mode control command, this change MUST before database initialization */ diff --git a/docs/zh-cn/api.md b/docs/zh-cn/api.md index 133a7fc..d6defbf 100644 --- a/docs/zh-cn/api.md +++ b/docs/zh-cn/api.md @@ -274,7 +274,7 @@ if (blob.saved.len > 0) { #define FDB_TSDB_CTRL_GET_SEC_SIZE 0x01 /**< 获取扇区大小 */ #define FDB_TSDB_CTRL_SET_LOCK 0x02 /**< 设置加锁函数 */ #define FDB_TSDB_CTRL_SET_UNLOCK 0x03 /**< 设置解锁函数 */ -#define FDB_TSDB_CTRL_SET_ROLLOVER 0x04 /**< 设置是否滚动写入,默认滚动。设置非滚动时,如果数据库写满,无法再追加写入。需要在数据库初始化前配置 */ +#define FDB_TSDB_CTRL_SET_ROLLOVER 0x04 /**< 设置是否滚动写入,默认滚动。设置非滚动时,如果数据库写满,无法再追加写入。需要在数据库初始化后配置 */ #define FDB_TSDB_CTRL_GET_ROLLOVER 0x05 /**< 获取是否滚动写入 */ #define FDB_TSDB_CTRL_GET_LAST_TIME 0x06 /**< 获取上次追加 TSL 时的时间戳 */ #define FDB_TSDB_CTRL_SET_FILE_MODE 0x09 /**< 设置文件模式,需要在数据库初始化前配置,需要在数据库初始化前配置 */ diff --git a/inc/fdb_def.h b/inc/fdb_def.h index 2d505af..eacf615 100644 --- a/inc/fdb_def.h +++ b/inc/fdb_def.h @@ -81,7 +81,7 @@ if (!(EXPR)) \ #define FDB_TSDB_CTRL_GET_SEC_SIZE 0x01 /**< get sector size control command */ #define FDB_TSDB_CTRL_SET_LOCK 0x02 /**< set lock function control command */ #define FDB_TSDB_CTRL_SET_UNLOCK 0x03 /**< set unlock function control command */ -#define FDB_TSDB_CTRL_SET_ROLLOVER 0x04 /**< set rollover control command, this change MUST before database initialization */ +#define FDB_TSDB_CTRL_SET_ROLLOVER 0x04 /**< set rollover control command, this change MUST after database initialization */ #define FDB_TSDB_CTRL_GET_ROLLOVER 0x05 /**< get rollover control command */ #define FDB_TSDB_CTRL_GET_LAST_TIME 0x06 /**< get last save time control command */ #define FDB_TSDB_CTRL_SET_FILE_MODE 0x09 /**< set file mode control command, this change MUST before database initialization */