summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-07-17 01:56:22 +0300
committerAndrei Karas <akaras@inbox.ru>2015-07-25 14:49:04 +0300
commitc654c6d8d29d41f404545342cceb41aa7f3c5817 (patch)
tree027bc808ca65fcb10a955a287a8036db172f5d58 /src
parent79ab58428bfde461fb4fa92418624982f181d036 (diff)
downloadhercules-c654c6d8d29d41f404545342cceb41aa7f3c5817.tar.gz
hercules-c654c6d8d29d41f404545342cceb41aa7f3c5817.tar.bz2
hercules-c654c6d8d29d41f404545342cceb41aa7f3c5817.tar.xz
hercules-c654c6d8d29d41f404545342cceb41aa7f3c5817.zip
Reduce memory usage in HPM in quest.c
Diffstat (limited to 'src')
-rw-r--r--src/map/quest.c2
-rw-r--r--src/map/quest.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/map/quest.c b/src/map/quest.c
index da5f73caa..463a3395a 100644
--- a/src/map/quest.c
+++ b/src/map/quest.c
@@ -37,6 +37,7 @@
#include <time.h>
struct quest_interface quest_s;
+struct quest_db *db_data[MAX_QUEST_DB]; ///< Quest database
/**
* Searches a quest by ID.
@@ -618,6 +619,7 @@ void do_reload_quest(void) {
*/
void quest_defaults(void) {
quest = &quest_s;
+ quest->db_data = db_data;
memset(&quest->db, 0, sizeof(quest->db));
memset(&quest->dummy, 0, sizeof(quest->dummy));
diff --git a/src/map/quest.h b/src/map/quest.h
index 014f82527..9b5199625 100644
--- a/src/map/quest.h
+++ b/src/map/quest.h
@@ -40,7 +40,7 @@ enum quest_check_type {
};
struct quest_interface {
- struct quest_db *db_data[MAX_QUEST_DB]; ///< Quest database
+ struct quest_db **db_data; ///< Quest database
struct quest_db dummy; ///< Dummy entry for invalid quest lookups
/* */
void (*init) (bool minimal);