[TBASE-1215]
This commit is contained in:
parent
8715de7fa2
commit
aeb19d1eb0
|
@ -346,7 +346,7 @@ typedef struct _tsc_obj {
|
|||
char user[TSDB_USER_LEN];
|
||||
char pass[TSDB_KEY_LEN];
|
||||
char acctId[TSDB_DB_NAME_LEN];
|
||||
char db[TSDB_DB_NAME_LEN];
|
||||
char db[TSDB_METER_ID_LEN];
|
||||
char sversion[TSDB_VERSION_LEN];
|
||||
char writeAuth : 1;
|
||||
char superAuth : 1;
|
||||
|
|
|
@ -1795,7 +1795,7 @@ int tscBuildCreateDbMsg(SSqlObj *pSql) {
|
|||
pMsg += sizeof(SMgmtHead);
|
||||
|
||||
pCreateDbMsg = (SCreateDbMsg *)pMsg;
|
||||
strcpy(pCreateDbMsg->db, pMeterMetaInfo->name);
|
||||
strncpy(pCreateDbMsg->db, pMeterMetaInfo->name, tListLen(pCreateDbMsg->db));
|
||||
pMsg += sizeof(SCreateDbMsg);
|
||||
|
||||
msgLen = pMsg - pStart;
|
||||
|
@ -2017,7 +2017,7 @@ int tscBuildDropDbMsg(SSqlObj *pSql) {
|
|||
pMsg += sizeof(SMgmtHead);
|
||||
|
||||
pDropDbMsg = (SDropDbMsg *)pMsg;
|
||||
strcpy(pDropDbMsg->db, pMeterMetaInfo->name);
|
||||
strncpy(pDropDbMsg->db, pMeterMetaInfo->name, tListLen(pDropDbMsg->db));
|
||||
|
||||
pDropDbMsg->ignoreNotExists = htons(pCmd->existsCheck ? 1 : 0);
|
||||
|
||||
|
|
|
@ -309,7 +309,7 @@ typedef struct {
|
|||
} SCreateMsg;
|
||||
|
||||
typedef struct {
|
||||
char db[TSDB_DB_NAME_LEN];
|
||||
char db[TSDB_METER_ID_LEN];
|
||||
short ignoreNotExists;
|
||||
} SDropDbMsg, SUseDbMsg;
|
||||
|
||||
|
@ -594,7 +594,7 @@ typedef struct {
|
|||
// NOTE: sizeof(SVnodeCfg) < TSDB_FILE_HEADER_LEN/4
|
||||
typedef struct {
|
||||
char acct[TSDB_USER_LEN];
|
||||
char db[TSDB_DB_NAME_LEN];
|
||||
char db[TSDB_METER_ID_LEN+2]; // 8bytes align
|
||||
uint32_t vgId;
|
||||
int32_t maxSessions;
|
||||
int32_t cacheBlockSize;
|
||||
|
|
|
@ -157,7 +157,7 @@ typedef struct _vg_obj {
|
|||
} SVgObj;
|
||||
|
||||
typedef struct _db_obj {
|
||||
char name[TSDB_DB_NAME_LEN + 1];
|
||||
char name[TSDB_METER_ID_LEN + 1];
|
||||
int64_t createdTime;
|
||||
SDbCfg cfg;
|
||||
int32_t numOfVgroups;
|
||||
|
|
Loading…
Reference in New Issue