From: nishi Date: Tue, 28 May 2024 03:24:25 +0000 (+0000) Subject: fix flag issue X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=aff57e5bdb0e1c6ca7481b136b9fb42e56e57532;p=dataworks.git fix flag issue git-svn-id: file:///raid/svn-main/nishi-dataworks/trunk@126 d4a5a174-5a4a-5b4b-b672-37683c10d7d5 --- diff --git a/Library/database_record.c b/Library/database_record.c index d2c40b9..e412110 100644 --- a/Library/database_record.c +++ b/Library/database_record.c @@ -51,6 +51,7 @@ void __dw_add_record(struct dataworks_db* db, uint64_t count, uint64_t dbindex, if(feof(db->fp)) break; if(!(dbentry.flag & DATAWORKS_V1_DBENTRY_USED)) { fseek(db->fp, -(1 + 8 + 8 + 1 + 1 + 8 + 8), SEEK_CUR); + buf[0] = 0; buf[0] |= DATAWORKS_V1_DBENTRY_USED; uint64_t writ = 0; if(dbentry.size <= size) { diff --git a/Library/exec.c b/Library/exec.c index e6add8e..910ae05 100644 --- a/Library/exec.c +++ b/Library/exec.c @@ -224,7 +224,7 @@ struct dataworks_db_result* __dataworks_database_execute_code(struct dataworks_d double dn = 123123; int64_t in = 123123; void* data[3]; - data[0] = "data"; + data[0] = "dataworks"; data[1] = &dn; data[2] = ∈ struct dataworks_db_result* dbr = dataworks_database_insert_record(db, data, "SSS");