summaryrefslogtreecommitdiff
path: root/src/common/db.h
diff options
context:
space:
mode:
authorcelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-07 11:35:13 +0000
committercelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-07 11:35:13 +0000
commit24ec5cc01a034fe378bc0e8dfb7426a2dbbf8563 (patch)
treeb5c5bcfdd52bea7f5b223653e24e757d1369551a /src/common/db.h
parent4bd24425858e186737a3dd60bbe1ee2f3a4a4e67 (diff)
downloadhercules-24ec5cc01a034fe378bc0e8dfb7426a2dbbf8563.tar.gz
hercules-24ec5cc01a034fe378bc0e8dfb7426a2dbbf8563.tar.bz2
hercules-24ec5cc01a034fe378bc0e8dfb7426a2dbbf8563.tar.xz
hercules-24ec5cc01a034fe378bc0e8dfb7426a2dbbf8563.zip
* Updated core and map-server to jA 1115~1137
* Fixed a typo in Volcano git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1206 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/common/db.h')
-rw-r--r--src/common/db.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/common/db.h b/src/common/db.h
index c31f5bfaa..11ed4f3e1 100644
--- a/src/common/db.h
+++ b/src/common/db.h
@@ -13,6 +13,7 @@ struct dbn {
int color;
void *key;
void *data;
+ int deleted; // 削除済みフラグ(db_foreach)
};
struct dbt {
@@ -24,7 +25,16 @@ struct dbt {
struct dbn *ht[HASH_SIZE];
int item_count; // vf?
const char* alloc_file; // DB?t@C
- int alloc_line; // DB?s
+ int alloc_line; // DB?s
+ // db_foreach 内部でdb_erase される対策として、
+ // db_foreach が終わるまでロックすることにする
+ struct db_free {
+ struct dbn *z;
+ struct dbn **root;
+ } *free_list;
+ int free_count;
+ int free_max;
+ int free_lock;
};
#define strdb_search(t,k) db_search((t),(void*)(k))