From f4d2db4c54de2df6416ddfd2dc494045a33f12fe Mon Sep 17 00:00:00 2001 From: Andrew Talbot Date: Tue, 14 Jul 2009 23:01:31 +0100 Subject: [PATCH] dbghelp: Constify some variables. --- dlls/dbghelp/dbghelp_private.h | 4 ++-- dlls/dbghelp/symbol.c | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/dlls/dbghelp/dbghelp_private.h b/dlls/dbghelp/dbghelp_private.h index 0ddcb93779d..0a014095b84 100644 --- a/dlls/dbghelp/dbghelp_private.h +++ b/dlls/dbghelp/dbghelp_private.h @@ -559,7 +559,7 @@ extern struct symt_function* unsigned long addr, unsigned long size, struct symt* type); extern BOOL symt_normalize_function(struct module* module, - struct symt_function* func); + const struct symt_function* func); extern void symt_add_func_line(struct module* module, struct symt_function* func, unsigned source_idx, int line_num, @@ -577,7 +577,7 @@ extern struct symt_block* unsigned pc, unsigned len); extern struct symt_block* symt_close_func_block(struct module* module, - struct symt_function* func, + const struct symt_function* func, struct symt_block* block, unsigned pc); extern struct symt_hierarchy_point* symt_add_function_point(struct module* module, diff --git a/dlls/dbghelp/symbol.c b/dlls/dbghelp/symbol.c index 366cadecf3c..34d00b2a021 100644 --- a/dlls/dbghelp/symbol.c +++ b/dlls/dbghelp/symbol.c @@ -486,7 +486,7 @@ struct symt_block* symt_open_func_block(struct module* module, } struct symt_block* symt_close_func_block(struct module* module, - struct symt_function* func, + const struct symt_function* func, struct symt_block* block, unsigned pc) { assert(func); @@ -518,7 +518,7 @@ struct symt_hierarchy_point* symt_add_function_point(struct module* module, return sym; } -BOOL symt_normalize_function(struct module* module, struct symt_function* func) +BOOL symt_normalize_function(struct module* module, const struct symt_function* func) { unsigned len; struct line_info* dli; @@ -771,7 +771,7 @@ static BOOL send_symbol(const struct sym_enum* se, const struct module_pair* pai return !se->cb(se->sym_info, se->sym_info->Size, se->user); } -static BOOL symt_enum_module(struct module_pair* pair, const regex_t* regex, +static BOOL symt_enum_module(const struct module_pair* pair, const regex_t* regex, const struct sym_enum* se) { void* ptr; @@ -792,7 +792,7 @@ static BOOL symt_enum_module(struct module_pair* pair, const regex_t* regex, return FALSE; } -static inline unsigned where_to_insert(const struct module* module, unsigned high, struct symt_ht* elt) +static inline unsigned where_to_insert(const struct module* module, unsigned high, const struct symt_ht* elt) { unsigned low = 0, mid = high / 2; ULONG64 addr; @@ -848,7 +848,7 @@ static BOOL resort_symbols(struct module* module) return module->sortlist_valid = TRUE; } -static void symt_get_length(struct symt* symt, ULONG64* size) +static void symt_get_length(const struct symt* symt, ULONG64* size) { DWORD type_index;