[TBASE-1215]

This commit is contained in:
lihui 2019-11-23 11:30:11 +08:00
parent 553df7ff5c
commit 30773c4ed2
2 changed files with 2 additions and 2 deletions

View File

@ -1807,7 +1807,7 @@ int tscBuildCreateDbMsg(SSqlObj *pSql) {
pMsg += sizeof(SMgmtHead);
pCreateDbMsg = (SCreateDbMsg *)pMsg;
strncpy(pCreateDbMsg->db, pMeterMetaInfo->name, tListLen(pCreateDbMsg->db));
(void)extractDBName(pMeterMetaInfo->name, pCreateDbMsg->db); // only send db name, then recombining db name + acctId on the mgmt
pMsg += sizeof(SCreateDbMsg);
msgLen = pMsg - pStart;

View File

@ -256,7 +256,7 @@ int mgmtCreateDb(SAcctObj *pAcct, SCreateDbMsg *pCreate) {
pDb = malloc(sizeof(SDbObj));
memset(pDb, 0, sizeof(SDbObj));
strcpy(pDb->name, pCreate->db);
sprintf(pDb->name, "%s.%s", pAcct->acctId, pCreate->db); // set fullname
strcpy(pCreate->acct, pAcct->user);
pDb->createdTime = taosGetTimestampMs();
pDb->cfg = *pCreate;