summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'src/core')
-rw-r--r--src/core/core-arraylist.c15
-rw-r--r--src/core/core-command.c2
-rw-r--r--src/core/core-config-file.c116
-rw-r--r--src/core/core-debug.c49
-rw-r--r--src/core/core-eval.c15
-rw-r--r--src/core/core-hashtable.c47
-rw-r--r--src/core/core-hashtable.h3
-rw-r--r--src/core/core-hdata.c24
-rw-r--r--src/core/core-hook.c18
-rw-r--r--src/core/core-infolist.c42
-rw-r--r--src/core/core-input.c3
-rw-r--r--src/core/core-list.c16
-rw-r--r--src/core/core-proxy.c18
-rw-r--r--src/core/hook/hook-command-run.c4
-rw-r--r--src/core/hook/hook-command.c14
-rw-r--r--src/core/hook/hook-completion.c2
-rw-r--r--src/core/hook/hook-config.c2
-rw-r--r--src/core/hook/hook-connect.c14
-rw-r--r--src/core/hook/hook-fd.c2
-rw-r--r--src/core/hook/hook-focus.c2
-rw-r--r--src/core/hook/hook-hdata.c2
-rw-r--r--src/core/hook/hook-hsignal.c2
-rw-r--r--src/core/hook/hook-info-hashtable.c2
-rw-r--r--src/core/hook/hook-info.c2
-rw-r--r--src/core/hook/hook-infolist.c2
-rw-r--r--src/core/hook/hook-line.c6
-rw-r--r--src/core/hook/hook-modifier.c2
-rw-r--r--src/core/hook/hook-print.c6
-rw-r--r--src/core/hook/hook-process.c12
-rw-r--r--src/core/hook/hook-signal.c2
-rw-r--r--src/core/hook/hook-timer.c2
-rw-r--r--src/core/hook/hook-url.c8
32 files changed, 234 insertions, 222 deletions
diff --git a/src/core/core-arraylist.c b/src/core/core-arraylist.c
index 44320b3f3..6f1a6f778 100644
--- a/src/core/core-arraylist.c
+++ b/src/core/core-arraylist.c
@@ -703,25 +703,24 @@ arraylist_print_log (struct t_arraylist *arraylist, const char *name)
{
int i;
- log_printf ("[arraylist %s (addr:0x%lx)]", name, arraylist);
+ log_printf ("[arraylist %s (addr:%p)]", name, arraylist);
log_printf (" size . . . . . . . . . : %d", arraylist->size);
log_printf (" size_alloc . . . . . . : %d", arraylist->size_alloc);
log_printf (" size_alloc_min . . . . : %d", arraylist->size_alloc_min);
log_printf (" sorted . . . . . . . . : %d", arraylist->sorted);
log_printf (" allow_duplicates . . . : %d", arraylist->allow_duplicates);
- log_printf (" data . . . . . . . . . : 0x%lx", arraylist->data);
+ log_printf (" data . . . . . . . . . : %p", arraylist->data);
if (arraylist->data)
{
for (i = 0; i < arraylist->size_alloc; i++)
{
- log_printf (" data[%08d] . . . : 0x%lx",
- i, arraylist->data[i]);
+ log_printf (" data[%08d] . . . : %p", i, arraylist->data[i]);
}
}
- log_printf (" callback_cmp . . . . . : 0x%lx", arraylist->callback_cmp);
- log_printf (" callback_cmp_data. . . : 0x%lx",
+ log_printf (" callback_cmp . . . . . : %p", arraylist->callback_cmp);
+ log_printf (" callback_cmp_data. . . : %p",
arraylist->callback_cmp_data);
- log_printf (" callback_free. . . . . : 0x%lx", arraylist->callback_free);
- log_printf (" callback_free_data . . : 0x%lx",
+ log_printf (" callback_free. . . . . : %p", arraylist->callback_free);
+ log_printf (" callback_free_data . . : %p",
arraylist->callback_free_data);
}
diff --git a/src/core/core-command.c b/src/core/core-command.c
index 54dd18bb3..f17abd01f 100644
--- a/src/core/core-command.c
+++ b/src/core/core-command.c
@@ -1395,7 +1395,7 @@ COMMAND_CALLBACK(buffer)
if (gui_buffer_property_in_list (gui_buffer_properties_get_pointer,
argv[2]))
{
- gui_chat_printf (NULL, "%s%s%s: (ptr) %s = 0x%lx",
+ gui_chat_printf (NULL, "%s%s%s: (ptr) %s = %p",
GUI_COLOR(GUI_COLOR_CHAT_BUFFER),
buffer->full_name,
GUI_COLOR(GUI_COLOR_CHAT),
diff --git a/src/core/core-config-file.c b/src/core/core-config-file.c
index ec637bc11..9fff969fc 100644
--- a/src/core/core-config-file.c
+++ b/src/core/core-config-file.c
@@ -4572,63 +4572,63 @@ config_file_print_log ()
ptr_config_file = ptr_config_file->next_config)
{
log_printf ("");
- log_printf ("[config (addr:0x%lx)]", ptr_config_file);
- log_printf (" plugin . . . . . . . . : 0x%lx ('%s')",
+ log_printf ("[config (addr:%p)]", ptr_config_file);
+ log_printf (" plugin . . . . . . . . : %p ('%s')",
ptr_config_file->plugin,
plugin_get_name (ptr_config_file->plugin));
- log_printf (" priority . . . . . . . : %d", ptr_config_file->priority);
- log_printf (" name . . . . . . . . . : '%s'", ptr_config_file->name);
- log_printf (" filename . . . . . . . : '%s'", ptr_config_file->filename);
- log_printf (" file . . . . . . . . . : 0x%lx", ptr_config_file->file);
- log_printf (" callback_reload. . . . : 0x%lx", ptr_config_file->callback_reload);
- log_printf (" callback_reload_pointer: 0x%lx", ptr_config_file->callback_reload_pointer);
- log_printf (" callback_reload_data . : 0x%lx", ptr_config_file->callback_reload_data);
- log_printf (" sections . . . . . . . : 0x%lx", ptr_config_file->sections);
- log_printf (" last_section . . . . . : 0x%lx", ptr_config_file->last_section);
- log_printf (" prev_config. . . . . . : 0x%lx", ptr_config_file->prev_config);
- log_printf (" next_config. . . . . . : 0x%lx", ptr_config_file->next_config);
+ log_printf (" priority . . . . . . . : %d", ptr_config_file->priority);
+ log_printf (" name . . . . . . . . . : '%s'", ptr_config_file->name);
+ log_printf (" filename . . . . . . . : '%s'", ptr_config_file->filename);
+ log_printf (" file . . . . . . . . . : %p", ptr_config_file->file);
+ log_printf (" callback_reload. . . . : %p", ptr_config_file->callback_reload);
+ log_printf (" callback_reload_pointer: %p", ptr_config_file->callback_reload_pointer);
+ log_printf (" callback_reload_data . : %p", ptr_config_file->callback_reload_data);
+ log_printf (" sections . . . . . . . : %p", ptr_config_file->sections);
+ log_printf (" last_section . . . . . : %p", ptr_config_file->last_section);
+ log_printf (" prev_config. . . . . . : %p", ptr_config_file->prev_config);
+ log_printf (" next_config. . . . . . : %p", ptr_config_file->next_config);
for (ptr_section = ptr_config_file->sections; ptr_section;
ptr_section = ptr_section->next_section)
{
log_printf ("");
- log_printf (" [section (addr:0x%lx)]", ptr_section);
- log_printf (" config_file . . . . . . . . . : 0x%lx", ptr_section->config_file);
- log_printf (" name. . . . . . . . . . . . . : '%s'", ptr_section->name);
- log_printf (" callback_read . . . . . . . . : 0x%lx", ptr_section->callback_read);
- log_printf (" callback_read_pointer . . . . : 0x%lx", ptr_section->callback_read_pointer);
- log_printf (" callback_read_data. . . . . . : 0x%lx", ptr_section->callback_read_data);
- log_printf (" callback_write. . . . . . . . : 0x%lx", ptr_section->callback_write);
- log_printf (" callback_write_pointer. . . . : 0x%lx", ptr_section->callback_write_pointer);
- log_printf (" callback_write_data . . . . . : 0x%lx", ptr_section->callback_write_data);
- log_printf (" callback_write_default. . . . : 0x%lx", ptr_section->callback_write_default);
- log_printf (" callback_write_default_pointer: 0x%lx", ptr_section->callback_write_default_pointer);
- log_printf (" callback_write_default_data . : 0x%lx", ptr_section->callback_write_default_data);
- log_printf (" callback_create_option. . . . : 0x%lx", ptr_section->callback_create_option);
- log_printf (" callback_create_option_pointer: 0x%lx", ptr_section->callback_create_option_pointer);
- log_printf (" callback_create_option_data . : 0x%lx", ptr_section->callback_create_option_data);
- log_printf (" callback_delete_option. . . . : 0x%lx", ptr_section->callback_delete_option);
- log_printf (" callback_delete_option_pointer: 0x%lx", ptr_section->callback_delete_option_pointer);
- log_printf (" callback_delete_option_data . : 0x%lx", ptr_section->callback_delete_option_data);
- log_printf (" options . . . . . . . . . . . : 0x%lx", ptr_section->options);
- log_printf (" last_option . . . . . . . . . : 0x%lx", ptr_section->last_option);
- log_printf (" prev_section. . . . . . . . . : 0x%lx", ptr_section->prev_section);
- log_printf (" next_section. . . . . . . . . : 0x%lx", ptr_section->next_section);
+ log_printf (" [section (addr:%p)]", ptr_section);
+ log_printf (" config_file . . . . . . . . . : %p", ptr_section->config_file);
+ log_printf (" name. . . . . . . . . . . . . : '%s'", ptr_section->name);
+ log_printf (" callback_read . . . . . . . . : %p", ptr_section->callback_read);
+ log_printf (" callback_read_pointer . . . . : %p", ptr_section->callback_read_pointer);
+ log_printf (" callback_read_data. . . . . . : %p", ptr_section->callback_read_data);
+ log_printf (" callback_write. . . . . . . . : %p", ptr_section->callback_write);
+ log_printf (" callback_write_pointer. . . . : %p", ptr_section->callback_write_pointer);
+ log_printf (" callback_write_data . . . . . : %p", ptr_section->callback_write_data);
+ log_printf (" callback_write_default. . . . : %p", ptr_section->callback_write_default);
+ log_printf (" callback_write_default_pointer: %p", ptr_section->callback_write_default_pointer);
+ log_printf (" callback_write_default_data . : %p", ptr_section->callback_write_default_data);
+ log_printf (" callback_create_option. . . . : %p", ptr_section->callback_create_option);
+ log_printf (" callback_create_option_pointer: %p", ptr_section->callback_create_option_pointer);
+ log_printf (" callback_create_option_data . : %p", ptr_section->callback_create_option_data);
+ log_printf (" callback_delete_option. . . . : %p", ptr_section->callback_delete_option);
+ log_printf (" callback_delete_option_pointer: %p", ptr_section->callback_delete_option_pointer);
+ log_printf (" callback_delete_option_data . : %p", ptr_section->callback_delete_option_data);
+ log_printf (" options . . . . . . . . . . . : %p", ptr_section->options);
+ log_printf (" last_option . . . . . . . . . : %p", ptr_section->last_option);
+ log_printf (" prev_section. . . . . . . . . : %p", ptr_section->prev_section);
+ log_printf (" next_section. . . . . . . . . : %p", ptr_section->next_section);
for (ptr_option = ptr_section->options; ptr_option;
ptr_option = ptr_option->next_option)
{
log_printf ("");
- log_printf (" [option (addr:0x%lx)]", ptr_option);
- log_printf (" config_file. . . . . . . . . : 0x%lx", ptr_option->config_file);
- log_printf (" section. . . . . . . . . . . : 0x%lx", ptr_option->section);
- log_printf (" name . . . . . . . . . . . . : '%s'", ptr_option->name);
- log_printf (" parent_name. . . . . . . . . : '%s'", ptr_option->parent_name);
- log_printf (" type . . . . . . . . . . . . : %d", ptr_option->type);
- log_printf (" description. . . . . . . . . : '%s'", ptr_option->description);
- log_printf (" string_values. . . . . . . . : 0x%lx", ptr_option->string_values);
- log_printf (" min. . . . . . . . . . . . . : %d", ptr_option->min);
- log_printf (" max. . . . . . . . . . . . . : %d", ptr_option->max);
+ log_printf (" [option (addr:%p)]", ptr_option);
+ log_printf (" config_file. . . . . . . . . : %p", ptr_option->config_file);
+ log_printf (" section. . . . . . . . . . . : %p", ptr_option->section);
+ log_printf (" name . . . . . . . . . . . . : '%s'", ptr_option->name);
+ log_printf (" parent_name. . . . . . . . . : '%s'", ptr_option->parent_name);
+ log_printf (" type . . . . . . . . . . . . : %d", ptr_option->type);
+ log_printf (" description. . . . . . . . . : '%s'", ptr_option->description);
+ log_printf (" string_values. . . . . . . . : %p", ptr_option->string_values);
+ log_printf (" min. . . . . . . . . . . . . : %d", ptr_option->min);
+ log_printf (" max. . . . . . . . . . . . . : %d", ptr_option->max);
switch (ptr_option->type)
{
case CONFIG_OPTION_TYPE_BOOLEAN:
@@ -4690,19 +4690,19 @@ config_file_print_log ()
case CONFIG_NUM_OPTION_TYPES:
break;
}
- log_printf (" null_value_allowed . . . . . : %d", ptr_option->null_value_allowed);
- log_printf (" callback_check_value . . . . : 0x%lx", ptr_option->callback_check_value);
- log_printf (" callback_check_value_pointer : 0x%lx", ptr_option->callback_check_value_pointer);
- log_printf (" callback_check_value_data. . : 0x%lx", ptr_option->callback_check_value_data);
- log_printf (" callback_change. . . . . . . : 0x%lx", ptr_option->callback_change);
- log_printf (" callback_change_pointer. . . : 0x%lx", ptr_option->callback_change_pointer);
- log_printf (" callback_change_data . . . . : 0x%lx", ptr_option->callback_change_data);
- log_printf (" callback_delete. . . . . . . : 0x%lx", ptr_option->callback_delete);
- log_printf (" callback_delete_pointer. . . : 0x%lx", ptr_option->callback_delete_pointer);
- log_printf (" callback_delete_data . . . . : 0x%lx", ptr_option->callback_delete_data);
- log_printf (" loaded . . . . . . . . . . . : %d", ptr_option->loaded);
- log_printf (" prev_option. . . . . . . . . : 0x%lx", ptr_option->prev_option);
- log_printf (" next_option. . . . . . . . . : 0x%lx", ptr_option->next_option);
+ log_printf (" null_value_allowed . . . . . : %d", ptr_option->null_value_allowed);
+ log_printf (" callback_check_value . . . . : %p", ptr_option->callback_check_value);
+ log_printf (" callback_check_value_pointer : %p", ptr_option->callback_check_value_pointer);
+ log_printf (" callback_check_value_data. . : %p", ptr_option->callback_check_value_data);
+ log_printf (" callback_change. . . . . . . : %p", ptr_option->callback_change);
+ log_printf (" callback_change_pointer. . . : %p", ptr_option->callback_change_pointer);
+ log_printf (" callback_change_data . . . . : %p", ptr_option->callback_change_data);
+ log_printf (" callback_delete. . . . . . . : %p", ptr_option->callback_delete);
+ log_printf (" callback_delete_pointer. . . : %p", ptr_option->callback_delete_pointer);
+ log_printf (" callback_delete_data . . . . : %p", ptr_option->callback_delete_data);
+ log_printf (" loaded . . . . . . . . . . . : %d", ptr_option->loaded);
+ log_printf (" prev_option. . . . . . . . . : %p", ptr_option->prev_option);
+ log_printf (" next_option. . . . . . . . . : %p", ptr_option->next_option);
}
}
}
diff --git a/src/core/core-debug.c b/src/core/core-debug.c
index fb40dcb71..d5153ca26 100644
--- a/src/core/core-debug.c
+++ b/src/core/core-debug.c
@@ -211,17 +211,26 @@ debug_windows_tree_display (struct t_gui_window_tree *tree, int indent)
/* leaf */
snprintf (format,
sizeof (format),
- "%%-%dsleaf: 0x%%lx, parent:0x%%lx, child1=0x%%lx, "
- "child2=0x%%lx, win=0x%%lx (%%d,%%d %%dx%%d"
- " %%d%%%%x%%d%%%%)",
+ "%%-%dsleaf: "
+ "%%p, "
+ "parent:%%p, "
+ "child1=%%p, "
+ "child2=%%p, "
+ "win=%%p "
+ "(%%d,%%d %%dx%%d %%d%%%%x%%d%%%%)",
indent * 2);
gui_chat_printf (NULL,
format,
- " ", tree, tree->parent_node,
- tree->child1, tree->child2,
+ " ",
+ tree,
+ tree->parent_node,
+ tree->child1,
+ tree->child2,
tree->window,
- tree->window->win_x, tree->window->win_y,
- tree->window->win_width, tree->window->win_height,
+ tree->window->win_x,
+ tree->window->win_y,
+ tree->window->win_width,
+ tree->window->win_height,
tree->window->win_width_pct,
tree->window->win_height_pct);
}
@@ -230,14 +239,23 @@ debug_windows_tree_display (struct t_gui_window_tree *tree, int indent)
/* node */
snprintf (format,
sizeof (format),
- "%%-%dsnode: 0x%%lx, parent:0x%%lx, pct:%%d, "
- "horizontal:%%d, child1=0x%%lx, child2=0x%%lx",
+ "%%-%dsnode: "
+ "0x%%lx, "
+ "parent:%%p, "
+ "pct:%%d, "
+ "horizontal:%%d, "
+ "child1=%%p, "
+ "child2=%%p",
indent * 2);
gui_chat_printf (NULL,
format,
- " ", tree, tree->parent_node, tree->split_pct,
+ " ",
+ tree,
+ tree->parent_node,
+ tree->split_pct,
tree->split_horizontal,
- tree->child1, tree->child2);
+ tree->child1,
+ tree->child2);
}
if (tree->child1)
@@ -346,7 +364,7 @@ debug_hdata_hash_list_map_cb (void *data,
(void) hashtable;
gui_chat_printf (NULL,
- " list: %s -> 0x%lx",
+ " list: %s -> %p",
(char *)key,
*((void **)value));
}
@@ -372,8 +390,9 @@ debug_hdata_map_cb (void *data,
ptr_hdata = (struct t_hdata *)value;
gui_chat_printf (NULL,
- " hdata 0x%lx: \"%s\", %d vars, %d lists:",
- ptr_hdata, (const char *)key,
+ " hdata %p: \"%s\", %d vars, %d lists:",
+ ptr_hdata,
+ (const char *)key,
ptr_hdata->hash_var->items_count,
ptr_hdata->hash_list->items_count);
@@ -618,7 +637,7 @@ debug_infolists ()
}
}
gui_chat_printf (NULL,
- "%4d: infolist 0x%lx: %d items, %d vars - "
+ "%4d: infolist %p: %d items, %d vars - "
"structs: %d, data: %d (total: %d bytes)",
i + 1, ptr_infolist, count_items, count_vars,
size_structs, size_data, size_structs + size_data);
diff --git a/src/core/core-eval.c b/src/core/core-eval.c
index 06bde6c2d..661a4d6e0 100644
--- a/src/core/core-eval.c
+++ b/src/core/core-eval.c
@@ -1166,7 +1166,7 @@ eval_hdata_get_value (struct t_hdata *hdata, void *pointer, const char *path,
int type, debug_id;
struct t_hashtable *hashtable;
- EVAL_DEBUG_MSG(1, "eval_hdata_get_value(\"%s\", 0x%lx, \"%s\")",
+ EVAL_DEBUG_MSG(1, "eval_hdata_get_value(\"%s\", %p, \"%s\")",
(hdata) ? hdata->name : "(null)",
pointer,
path);
@@ -1184,8 +1184,7 @@ eval_hdata_get_value (struct t_hdata *hdata, void *pointer, const char *path,
/* no path? just return current pointer as string */
if (!path || !path[0])
{
- snprintf (str_value, sizeof (str_value),
- "0x%lx", (unsigned long)pointer);
+ snprintf (str_value, sizeof (str_value), "%p", pointer);
value = strdup (str_value);
goto end;
}
@@ -1242,8 +1241,7 @@ eval_hdata_get_value (struct t_hdata *hdata, void *pointer, const char *path,
break;
case WEECHAT_HDATA_POINTER:
pointer = hdata_pointer (hdata, pointer, var_name);
- snprintf (str_value, sizeof (str_value),
- "0x%lx", (unsigned long)pointer);
+ snprintf (str_value, sizeof (str_value), "%p", pointer);
value = strdup (str_value);
break;
case WEECHAT_HDATA_TIME:
@@ -1293,7 +1291,7 @@ eval_hdata_get_value (struct t_hdata *hdata, void *pointer, const char *path,
case HASHTABLE_POINTER:
case HASHTABLE_BUFFER:
snprintf (str_value, sizeof (str_value),
- "0x%lx", (unsigned long)ptr_value);
+ "%p", ptr_value);
value = strdup (str_value);
break;
case HASHTABLE_TIME:
@@ -1308,8 +1306,7 @@ eval_hdata_get_value (struct t_hdata *hdata, void *pointer, const char *path,
}
else
{
- snprintf (str_value, sizeof (str_value),
- "0x%lx", (unsigned long)pointer);
+ snprintf (str_value, sizeof (str_value), "%p", pointer);
value = strdup (str_value);
}
break;
@@ -2459,7 +2456,7 @@ eval_replace_regex (const char *string, regex_t *regex, const char *replace,
result = NULL;
- EVAL_DEBUG_MSG(1, "eval_replace_regex(\"%s\", 0x%lx, \"%s\")",
+ EVAL_DEBUG_MSG(1, "eval_replace_regex(\"%s\", %p, \"%s\")",
string, regex, replace);
if (!string || !regex || !replace)
diff --git a/src/core/core-hashtable.c b/src/core/core-hashtable.c
index b7c92a90f..20f56afe2 100644
--- a/src/core/core-hashtable.c
+++ b/src/core/core-hashtable.c
@@ -561,8 +561,7 @@ hashtable_to_string (enum t_hashtable_type type, const void *value)
break;
case HASHTABLE_POINTER:
case HASHTABLE_BUFFER:
- snprintf (str_value, sizeof (str_value),
- "0x%lx", (unsigned long)value);
+ snprintf (str_value, sizeof (str_value), "%p", value);
return str_value;
break;
case HASHTABLE_TIME:
@@ -1302,31 +1301,31 @@ hashtable_print_log (struct t_hashtable *hashtable, const char *name)
int i;
log_printf ("");
- log_printf ("[hashtable %s (addr:0x%lx)]", name, hashtable);
- log_printf (" size . . . . . . . . . : %d", hashtable->size);
- log_printf (" htable . . . . . . . . : 0x%lx", hashtable->htable);
- log_printf (" items_count. . . . . . : %d", hashtable->items_count);
- log_printf (" oldest_item. . . . . . : 0x%lx", hashtable->oldest_item);
- log_printf (" newest_item. . . . . . : 0x%lx", hashtable->newest_item);
+ log_printf ("[hashtable %s (addr:%p)]", name, hashtable);
+ log_printf (" size . . . . . . . . . : %d", hashtable->size);
+ log_printf (" htable . . . . . . . . : %p", hashtable->htable);
+ log_printf (" items_count. . . . . . : %d", hashtable->items_count);
+ log_printf (" oldest_item. . . . . . : %p", hashtable->oldest_item);
+ log_printf (" newest_item. . . . . . : %p", hashtable->newest_item);
log_printf (" type_keys. . . . . . . : %d (%s)",
hashtable->type_keys,
hashtable_type_string[hashtable->type_keys]);
log_printf (" type_values. . . . . . : %d (%s)",
hashtable->type_values,
hashtable_type_string[hashtable->type_values]);
- log_printf (" callback_hash_key. . . : 0x%lx", hashtable->callback_hash_key);
- log_printf (" callback_keycmp. . . . : 0x%lx", hashtable->callback_keycmp);
- log_printf (" callback_free_key. . . : 0x%lx", hashtable->callback_free_key);
- log_printf (" callback_free_value. . : 0x%lx", hashtable->callback_free_value);
- log_printf (" keys_values. . . . . . : '%s'", hashtable->keys_values);
+ log_printf (" callback_hash_key. . . : %p", hashtable->callback_hash_key);
+ log_printf (" callback_keycmp. . . . : %p", hashtable->callback_keycmp);
+ log_printf (" callback_free_key. . . : %p", hashtable->callback_free_key);
+ log_printf (" callback_free_value. . : %p", hashtable->callback_free_value);
+ log_printf (" keys_values. . . . . . : '%s'", hashtable->keys_values);
for (i = 0; i < hashtable->size; i++)
{
- log_printf (" htable[%06d] . . . . : 0x%lx", i, hashtable->htable[i]);
+ log_printf (" htable[%06d] . . . . : %p", i, hashtable->htable[i]);
for (ptr_item = hashtable->htable[i]; ptr_item;
ptr_item = ptr_item->next_item)
{
- log_printf (" [item 0x%lx]", hashtable->htable);
+ log_printf (" [item %p]", hashtable->htable);
switch (hashtable->type_keys)
{
case HASHTABLE_INTEGER:
@@ -1336,10 +1335,10 @@ hashtable_print_log (struct t_hashtable *hashtable, const char *name)
log_printf (" key (string) . . . : '%s'", (char *)ptr_item->key);
break;
case HASHTABLE_POINTER:
- log_printf (" key (pointer). . . : 0x%lx", ptr_item->key);
+ log_printf (" key (pointer). . . : %p", ptr_item->key);
break;
case HASHTABLE_BUFFER:
- log_printf (" key (buffer) . . . : 0x%lx", ptr_item->key);
+ log_printf (" key (buffer) . . . : %p", ptr_item->key);
break;
case HASHTABLE_TIME:
log_printf (" key (time) . . . . : %lld", (long long)(*((time_t *)ptr_item->key)));
@@ -1357,10 +1356,10 @@ hashtable_print_log (struct t_hashtable *hashtable, const char *name)
log_printf (" value (string) . . : '%s'", (char *)ptr_item->value);
break;
case HASHTABLE_POINTER:
- log_printf (" value (pointer). . : 0x%lx", ptr_item->value);
+ log_printf (" value (pointer). . : %p", ptr_item->value);
break;
case HASHTABLE_BUFFER:
- log_printf (" value (buffer) . . : 0x%lx", ptr_item->value);
+ log_printf (" value (buffer) . . : %p", ptr_item->value);
break;
case HASHTABLE_TIME:
log_printf (" value (time) . . . : %lld", (long long)(*((time_t *)ptr_item->value)));
@@ -1368,11 +1367,11 @@ hashtable_print_log (struct t_hashtable *hashtable, const char *name)
case HASHTABLE_NUM_TYPES:
break;
}
- log_printf (" value_size . . . . : %d", ptr_item->value_size);
- log_printf (" prev_item. . . . . : 0x%lx", ptr_item->prev_item);
- log_printf (" next_item. . . . . : 0x%lx", ptr_item->next_item);
- log_printf (" prev_created_item. : 0x%lx", ptr_item->prev_created_item);
- log_printf (" next_created_item. : 0x%lx", ptr_item->next_created_item);
+ log_printf (" value_size . . . . : %d", ptr_item->value_size);
+ log_printf (" prev_item. . . . . : %p", ptr_item->prev_item);
+ log_printf (" next_item. . . . . : %p", ptr_item->next_item);
+ log_printf (" prev_created_item. : %p", ptr_item->prev_created_item);
+ log_printf (" next_created_item. : %p", ptr_item->next_created_item);
}
}
}
diff --git a/src/core/core-hashtable.h b/src/core/core-hashtable.h
index 9ba78e1a3..b2c8a8fa3 100644
--- a/src/core/core-hashtable.h
+++ b/src/core/core-hashtable.h
@@ -43,8 +43,7 @@ struct t_infolist_item;
#define HASHTABLE_SET_POINTER(__name, __pointer) \
if (__pointer) \
{ \
- snprintf (str_value, sizeof (str_value), \
- "0x%lx", (unsigned long)__pointer); \
+ snprintf (str_value, sizeof (str_value), "%p", __pointer); \
hashtable_set (hashtable, __name, str_value); \
} \
else \
diff --git a/src/core/core-hdata.c b/src/core/core-hdata.c
index a3f4e195d..c6aab2b4d 100644
--- a/src/core/core-hdata.c
+++ b/src/core/core-hdata.c
@@ -1504,22 +1504,22 @@ hdata_print_log_map_cb (void *data, struct t_hashtable *hashtable,
ptr_hdata = (struct t_hdata *)value;
log_printf ("");
- log_printf ("[hdata (addr:0x%lx)]", ptr_hdata);
- log_printf (" name . . . . . . . . . : '%s'", ptr_hdata->name);
- log_printf (" plugin . . . . . . . . : 0x%lx", ptr_hdata->plugin);
- log_printf (" var_prev . . . . . . . : '%s'", ptr_hdata->var_prev);
- log_printf (" var_next . . . . . . . : '%s'", ptr_hdata->var_next);
- log_printf (" hash_var . . . . . . . : 0x%lx (hashtable: '%s')",
+ log_printf ("[hdata (addr:%p)]", ptr_hdata);
+ log_printf (" name . . . . . . . . . : '%s'", ptr_hdata->name);
+ log_printf (" plugin . . . . . . . . : %p", ptr_hdata->plugin);
+ log_printf (" var_prev . . . . . . . : '%s'", ptr_hdata->var_prev);
+ log_printf (" var_next . . . . . . . : '%s'", ptr_hdata->var_next);
+ log_printf (" hash_var . . . . . . . : %p (hashtable: '%s')",
ptr_hdata->hash_var,
hashtable_get_string (ptr_hdata->hash_var, "keys_values"));
- log_printf (" hash_list. . . . . . . : 0x%lx (hashtable: '%s')",
+ log_printf (" hash_list. . . . . . . : %p (hashtable: '%s')",
ptr_hdata->hash_list,
hashtable_get_string (ptr_hdata->hash_list, "keys_values"));
- log_printf (" create_allowed . . . . : %d", (int)ptr_hdata->create_allowed);
- log_printf (" delete_allowed . . . . : %d", (int)ptr_hdata->delete_allowed);
- log_printf (" callback_update. . . . : 0x%lx", ptr_hdata->callback_update);
- log_printf (" callback_update_data . : 0x%lx", ptr_hdata->callback_update_data);
- log_printf (" update_pending . . . . : %d", (int)ptr_hdata->update_pending);
+ log_printf (" create_allowed . . . . : %d", (int)ptr_hdata->create_allowed);
+ log_printf (" delete_allowed . . . . : %d", (int)ptr_hdata->delete_allowed);
+ log_printf (" callback_update. . . . : %p", ptr_hdata->callback_update);
+ log_printf (" callback_update_data . : %p", ptr_hdata->callback_update_data);
+ log_printf (" update_pending . . . . : %d", (int)ptr_hdata->update_pending);
hashtable_map (ptr_hdata->hash_var, &hdata_print_log_var_map_cb, NULL);
}
diff --git a/src/core/core-hook.c b/src/core/core-hook.c
index d89c2f988..1b6d1560d 100644
--- a/src/core/core-hook.c
+++ b/src/core/core-hook.c
@@ -929,24 +929,24 @@ hook_print_log ()
ptr_hook = ptr_hook->next_hook)
{
log_printf ("");
- log_printf ("[hook (addr:0x%lx)]", ptr_hook);
- log_printf (" plugin. . . . . . . . . : 0x%lx ('%s')",
+ log_printf ("[hook (addr:%p)]", ptr_hook);
+ log_printf (" plugin. . . . . . . . . : %p ('%s')",
ptr_hook->plugin, plugin_get_name (ptr_hook->plugin));
log_printf (" subplugin . . . . . . . : '%s'", ptr_hook->subplugin);
log_printf (" type. . . . . . . . . . : %d (%s)",
ptr_hook->type, hook_type_string[ptr_hook->type]);
- log_printf (" deleted . . . . . . . . : %d", ptr_hook->deleted);
- log_printf (" running . . . . . . . . : %d", ptr_hook->running);
- log_printf (" priority. . . . . . . . : %d", ptr_hook->priority);
- log_printf (" callback_pointer. . . . : 0x%lx", ptr_hook->callback_pointer);
- log_printf (" callback_data . . . . . : 0x%lx", ptr_hook->callback_data);
+ log_printf (" deleted . . . . . . . . : %d", ptr_hook->deleted);
+ log_printf (" running . . . . . . . . : %d", ptr_hook->running);
+ log_printf (" priority. . . . . . . . : %d", ptr_hook->priority);
+ log_printf (" callback_pointer. . . . : %p", ptr_hook->callback_pointer);
+ log_printf (" callback_data . . . . . : %p", ptr_hook->callback_data);
if (ptr_hook->deleted)
continue;
(hook_callback_print_log[ptr_hook->type]) (ptr_hook);
- log_printf (" prev_hook . . . . . . . : 0x%lx", ptr_hook->prev_hook);
- log_printf (" next_hook . . . . . . . : 0x%lx", ptr_hook->next_hook);
+ log_printf (" prev_hook . . . . . . . : %p", ptr_hook->prev_hook);
+ log_printf (" next_hook . . . . . . . : %p", ptr_hook->next_hook);
}
}
}
diff --git a/src/core/core-infolist.c b/src/core/core-infolist.c
index 652482db5..18a4bc524 100644
--- a/src/core/core-infolist.c
+++ b/src/core/core-infolist.c
@@ -722,45 +722,45 @@ infolist_print_log ()
ptr_infolist = ptr_infolist->next_infolist)
{
log_printf ("");
- log_printf ("[infolist (addr:0x%lx)]", ptr_infolist);
- log_printf (" plugin . . . . . . . . : 0x%lx", ptr_infolist->plugin);
- log_printf (" items. . . . . . . . . : 0x%lx", ptr_infolist->items);
- log_printf (" last_item. . . . . . . : 0x%lx", ptr_infolist->last_item);
- log_printf (" ptr_item . . . . . . . : 0x%lx", ptr_infolist->ptr_item);
- log_printf (" prev_infolist. . . . . : 0x%lx", ptr_infolist->prev_infolist);
- log_printf (" next_infolist. . . . . : 0x%lx", ptr_infolist->next_infolist);
+ log_printf ("[infolist (addr:%p)]", ptr_infolist);
+ log_printf (" plugin . . . . . . . . : %p", ptr_infolist->plugin);
+ log_printf (" items. . . . . . . . . : %p", ptr_infolist->items);
+ log_printf (" last_item. . . . . . . : %p", ptr_infolist->last_item);
+ log_printf (" ptr_item . . . . . . . : %p", ptr_infolist->ptr_item);
+ log_printf (" prev_infolist. . . . . : %p", ptr_infolist->prev_infolist);
+ log_printf (" next_infolist. . . . . : %p", ptr_infolist->next_infolist);
for (ptr_item = ptr_infolist->items; ptr_item;
ptr_item = ptr_item->next_item)
{
log_printf ("");
- log_printf (" [item (addr:0x%lx)]", ptr_item);
- log_printf (" vars . . . . . . . . . : 0x%lx", ptr_item->vars);
- log_printf (" last_var . . . . . . . : 0x%lx", ptr_item->last_var);
- log_printf (" prev_item. . . . . . . : 0x%lx", ptr_item->prev_item);
- log_printf (" next_item. . . . . . . : 0x%lx", ptr_item->next_item);
+ log_printf (" [item (addr:%p)]", ptr_item);
+ log_printf (" vars . . . . . . . . . : %p", ptr_item->vars);
+ log_printf (" last_var . . . . . . . : %p", ptr_item->last_var);
+ log_printf (" prev_item. . . . . . . : %p", ptr_item->prev_item);
+ log_printf (" next_item. . . . . . . : %p", ptr_item->next_item);
for (ptr_var = ptr_item->vars; ptr_var;
ptr_var = ptr_var->next_var)
{
log_printf ("");
- log_printf (" [var (addr:0x%lx)]", ptr_var);
+ log_printf (" [var (addr:%p)]", ptr_var);
log_printf (" name . . . . . . . . : '%s'", ptr_var->name);
- log_printf (" type . . . . . . . . : %d", ptr_var->type);
+ log_printf (" type . . . . . . . . : %d", ptr_var->type);
switch (ptr_var->type)
{
case INFOLIST_INTEGER:
- log_printf (" value (integer). . . : %d", *((int *)ptr_var->value));
+ log_printf (" value (integer). . . : %d", *((int *)ptr_var->value));
break;
case INFOLIST_STRING:
- log_printf (" value (string) . . . : '%s'", (char *)ptr_var->value);
+ log_printf (" value (string) . . . : '%s'", (char *)ptr_var->value);
break;
case INFOLIST_POINTER:
- log_printf (" value (pointer). . . : 0x%lx", ptr_var->value);
+ log_printf (" value (pointer). . . : %p", ptr_var->value);
break;
case INFOLIST_BUFFER:
- log_printf (" value (buffer) . . . : 0x%lx", ptr_var->value);
- log_printf (" size of buffer . . . : %d", ptr_var->size);
+ log_printf (" value (buffer) . . . : %p", ptr_var->value);
+ log_printf (" size of buffer . . . : %d", ptr_var->size);
break;
case INFOLIST_TIME:
log_printf (" value (time) . . . . : %lld", (long long)(*((time_t *)ptr_var->value)));
@@ -768,8 +768,8 @@ infolist_print_log ()
case INFOLIST_NUM_TYPES:
break;
}
- log_printf (" prev_var . . . . . . : 0x%lx", ptr_var->prev_var);
- log_printf (" next_var . . . . . . : 0x%lx", ptr_var->next_var);
+ log_printf (" prev_var . . . . . . : %p", ptr_var->prev_var);
+ log_printf (" next_var . . . . . . : %p", ptr_var->next_var);
}
}
}
diff --git a/src/core/core-input.c b/src/core/core-input.c
index b1585642d..d09f0aad8 100644
--- a/src/core/core-input.c
+++ b/src/core/core-input.c
@@ -268,8 +268,7 @@ input_data (struct t_gui_buffer *buffer, const char *data,
}
/* execute modifier "input_text_for_buffer" */
- snprintf (str_buffer, sizeof (str_buffer),
- "0x%lx", (unsigned long)buffer);
+ snprintf (str_buffer, sizeof (str_buffer), "%p", buffer);
new_data = hook_modifier_exec (NULL,
"input_text_for_buffer",
str_buffer,
diff --git a/src/core/core-list.c b/src/core/core-list.c
index 62634ffbe..5e3dc5d32 100644
--- a/src/core/core-list.c
+++ b/src/core/core-list.c
@@ -450,20 +450,20 @@ weelist_print_log (struct t_weelist *weelist, const char *name)
struct t_weelist_item *ptr_item;
int i;
- log_printf ("[weelist %s (addr:0x%lx)]", name, weelist);
- log_printf (" items. . . . . . . . . : 0x%lx", weelist->items);
- log_printf (" last_item. . . . . . . : 0x%lx", weelist->last_item);
+ log_printf ("[weelist %s (addr:%p)]", name, weelist);
+ log_printf (" items. . . . . . . . . : %p", weelist->items);
+ log_printf (" last_item. . . . . . . : %p", weelist->last_item);
log_printf (" size . . . . . . . . . : %d", weelist->size);
i = 0;
for (ptr_item = weelist->items; ptr_item;
ptr_item = ptr_item->next_item)
{
- log_printf (" [item %d (addr:0x%lx)]", i, ptr_item);
- log_printf (" data . . . . . . . . : '%s'", ptr_item->data);
- log_printf (" user_data. . . . . . : 0x%lx", ptr_item->user_data);
- log_printf (" prev_item. . . . . . : 0x%lx", ptr_item->prev_item);
- log_printf (" next_item. . . . . . : 0x%lx", ptr_item->next_item);
+ log_printf (" [item %d (addr:%p)]", i, ptr_item);
+ log_printf (" data . . . . . . . . : '%s'", ptr_item->data);
+ log_printf (" user_data. . . . . . : %p", ptr_item->user_data);
+ log_printf (" prev_item. . . . . . : %p", ptr_item->prev_item);
+ log_printf (" next_item. . . . . . : %p", ptr_item->next_item);
i++;
}
}
diff --git a/src/core/core-proxy.c b/src/core/core-proxy.c
index 705776cdf..a88db0929 100644
--- a/src/core/core-proxy.c
+++ b/src/core/core-proxy.c
@@ -664,17 +664,17 @@ proxy_print_log ()
ptr_proxy = ptr_proxy->next_proxy)
{
log_printf ("");
- log_printf ("[proxy (addr:0x%lx)]", ptr_proxy);
- log_printf (" name . . . . . . . . . : '%s'", ptr_proxy->name);
+ log_printf ("[proxy (addr:%p)]", ptr_proxy);
+ log_printf (" name . . . . . . . . . : '%s'", ptr_proxy->name);
log_printf (" type . . . . . . . . . : %d (%s)",
CONFIG_ENUM(ptr_proxy->options[PROXY_OPTION_TYPE]),
proxy_type_string[CONFIG_ENUM(ptr_proxy->options[PROXY_OPTION_TYPE])]);
- log_printf (" ipv6 . . . . . . . . . : %d", CONFIG_INTEGER(ptr_proxy->options[PROXY_OPTION_IPV6]));
- log_printf (" address. . . . . . . . : '%s'", CONFIG_STRING(ptr_proxy->options[PROXY_OPTION_ADDRESS]));
- log_printf (" port . . . . . . . . . : %d", CONFIG_INTEGER(ptr_proxy->options[PROXY_OPTION_PORT]));
- log_printf (" username . . . . . . . : '%s'", CONFIG_STRING(ptr_proxy->options[PROXY_OPTION_USERNAME]));
- log_printf (" password . . . . . . . : '%s'", CONFIG_STRING(ptr_proxy->options[PROXY_OPTION_PASSWORD]));
- log_printf (" prev_proxy . . . . . . : 0x%lx", ptr_proxy->prev_proxy);
- log_printf (" next_proxy . . . . . . : 0x%lx", ptr_proxy->next_proxy);
+ log_printf (" ipv6 . . . . . . . . . : %d", CONFIG_INTEGER(ptr_proxy->options[PROXY_OPTION_IPV6]));
+ log_printf (" address. . . . . . . . : '%s'", CONFIG_STRING(ptr_proxy->options[PROXY_OPTION_ADDRESS]));
+ log_printf (" port . . . . . . . . . : %d", CONFIG_INTEGER(ptr_proxy->options[PROXY_OPTION_PORT]));
+ log_printf (" username . . . . . . . : '%s'", CONFIG_STRING(ptr_proxy->options[PROXY_OPTION_USERNAME]));
+ log_printf (" password . . . . . . . : '%s'", CONFIG_STRING(ptr_proxy->options[PROXY_OPTION_PASSWORD]));
+ log_printf (" prev_proxy . . . . . . : %p", ptr_proxy->prev_proxy);
+ log_printf (" next_proxy . . . . . . : %p", ptr_proxy->next_proxy);
}
}
diff --git a/src/core/hook/hook-command-run.c b/src/core/hook/hook-command-run.c
index 1c72543c2..e664c7709 100644
--- a/src/core/hook/hook-command-run.c
+++ b/src/core/hook/hook-command-run.c
@@ -229,6 +229,6 @@ hook_command_run_print_log (struct t_hook *hook)
return;
log_printf (" command_run data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_COMMAND_RUN(hook, callback));
- log_printf (" command . . . . . . . : '%s'", HOOK_COMMAND_RUN(hook, command));
+ log_printf (" callback. . . . . . . : %p", HOOK_COMMAND_RUN(hook, callback));
+ log_printf (" command . . . . . . . : '%s'", HOOK_COMMAND_RUN(hook, command));
}
diff --git a/src/core/hook/hook-command.c b/src/core/hook/hook-command.c
index 2558d52ab..d31972719 100644
--- a/src/core/hook/hook-command.c
+++ b/src/core/hook/hook-command.c
@@ -1108,13 +1108,13 @@ hook_command_print_log (struct t_hook *hook)
return;
log_printf (" command data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_COMMAND(hook, callback));
- log_printf (" command . . . . . . . : '%s'", HOOK_COMMAND(hook, command));
- log_printf (" description . . . . . : '%s'", HOOK_COMMAND(hook, description));
- log_printf (" args. . . . . . . . . : '%s'", HOOK_COMMAND(hook, args));
- log_printf (" args_description. . . : '%s'", HOOK_COMMAND(hook, args_description));
- log_printf (" completion. . . . . . : '%s'", HOOK_COMMAND(hook, completion));
- log_printf (" cplt_num_templates. . : %d", HOOK_COMMAND(hook, cplt_num_templates));
+ log_printf (" callback. . . . . . . : %p", HOOK_COMMAND(hook, callback));
+ log_printf (" command . . . . . . . : '%s'", HOOK_COMMAND(hook, command));
+ log_printf (" description . . . . . : '%s'", HOOK_COMMAND(hook, description));
+ log_printf (" args. . . . . . . . . : '%s'", HOOK_COMMAND(hook, args));
+ log_printf (" args_description. . . : '%s'", HOOK_COMMAND(hook, args_description));
+ log_printf (" completion. . . . . . : '%s'", HOOK_COMMAND(hook, completion));
+ log_printf (" cplt_num_templates. . : %d", HOOK_COMMAND(hook, cplt_num_templates));
for (i = 0; i < HOOK_COMMAND(hook, cplt_num_templates); i++)
{
log_printf (" cplt_templates[%04d] . . . : '%s'",
diff --git a/src/core/hook/hook-completion.c b/src/core/hook/hook-completion.c
index 063572e79..44618f129 100644
--- a/src/core/hook/hook-completion.c
+++ b/src/core/hook/hook-completion.c
@@ -219,7 +219,7 @@ hook_completion_print_log (struct t_hook *hook)
return;
log_printf (" completion data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_COMPLETION(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_COMPLETION(hook, callback));
log_printf (" completion_item . . . : '%s'", HOOK_COMPLETION(hook, completion_item));
log_printf (" description . . . . . : '%s'", HOOK_COMPLETION(hook, description));
}
diff --git a/src/core/hook/hook-config.c b/src/core/hook/hook-config.c
index 42b158b55..c6784378b 100644
--- a/src/core/hook/hook-config.c
+++ b/src/core/hook/hook-config.c
@@ -181,6 +181,6 @@ hook_config_print_log (struct t_hook *hook)
return;
log_printf (" config data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_CONFIG(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_CONFIG(hook, callback));
log_printf (" option. . . . . . . . : '%s'", HOOK_CONFIG(hook, option));
}
diff --git a/src/core/hook/hook-connect.c b/src/core/hook/hook-connect.c
index d6da88ba8..f93b902e2 100644
--- a/src/core/hook/hook-connect.c
+++ b/src/core/hook/hook-connect.c
@@ -388,15 +388,15 @@ hook_connect_print_log (struct t_hook *hook)
return;
log_printf (" connect data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_CONNECT(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_CONNECT(hook, callback));
log_printf (" proxy . . . . . . . . : '%s'", HOOK_CONNECT(hook, proxy));
log_printf (" address . . . . . . . : '%s'", HOOK_CONNECT(hook, address));
log_printf (" port. . . . . . . . . : %d", HOOK_CONNECT(hook, port));
log_printf (" sock. . . . . . . . . : %d", HOOK_CONNECT(hook, sock));
log_printf (" ipv6. . . . . . . . . : %d", HOOK_CONNECT(hook, ipv6));
log_printf (" retry . . . . . . . . : %d", HOOK_CONNECT(hook, retry));
- log_printf (" gnutls_sess . . . . . : 0x%lx", HOOK_CONNECT(hook, gnutls_sess));
- log_printf (" gnutls_cb . . . . . . : 0x%lx", HOOK_CONNECT(hook, gnutls_cb));
+ log_printf (" gnutls_sess . . . . . : %p", HOOK_CONNECT(hook, gnutls_sess));
+ log_printf (" gnutls_cb . . . . . . : %p", HOOK_CONNECT(hook, gnutls_cb));
log_printf (" gnutls_dhkey_size . . : %d", HOOK_CONNECT(hook, gnutls_dhkey_size));
log_printf (" gnutls_priorities . . : '%s'", HOOK_CONNECT(hook, gnutls_priorities));
log_printf (" local_hostname. . . . : '%s'", HOOK_CONNECT(hook, local_hostname));
@@ -405,10 +405,10 @@ hook_connect_print_log (struct t_hook *hook)
log_printf (" child_recv. . . . . . : %d", HOOK_CONNECT(hook, child_recv));
log_printf (" child_send. . . . . . : %d", HOOK_CONNECT(hook, child_send));
log_printf (" child_pid . . . . . . : %d", HOOK_CONNECT(hook, child_pid));
- log_printf (" hook_child_timer. . . : 0x%lx", HOOK_CONNECT(hook, hook_child_timer));
- log_printf (" hook_fd . . . . . . . : 0x%lx", HOOK_CONNECT(hook, hook_fd));
- log_printf (" handshake_hook_fd . . : 0x%lx", HOOK_CONNECT(hook, handshake_hook_fd));
- log_printf (" handshake_hook_timer. : 0x%lx", HOOK_CONNECT(hook, handshake_hook_timer));
+ log_printf (" hook_child_timer. . . : %p", HOOK_CONNECT(hook, hook_child_timer));
+ log_printf (" hook_fd . . . . . . . : %p", HOOK_CONNECT(hook, hook_fd));
+ log_printf (" handshake_hook_fd . . : %p", HOOK_CONNECT(hook, handshake_hook_fd));
+ log_printf (" handshake_hook_timer. : %p", HOOK_CONNECT(hook, handshake_hook_timer));
log_printf (" handshake_fd_flags. . : %d", HOOK_CONNECT(hook, handshake_fd_flags));
log_printf (" handshake_ip_address. : '%s'", HOOK_CONNECT(hook, handshake_ip_address));
if (!hook_socketpair_ok)
diff --git a/src/core/hook/hook-fd.c b/src/core/hook/hook-fd.c
index abc4f6d93..0405daed7 100644
--- a/src/core/hook/hook-fd.c
+++ b/src/core/hook/hook-fd.c
@@ -347,7 +347,7 @@ hook_fd_print_log (struct t_hook *hook)
return;
log_printf (" fd data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_FD(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_FD(hook, callback));
log_printf (" fd. . . . . . . . . . : %d", HOOK_FD(hook, fd));
log_printf (" flags . . . . . . . . : %d", HOOK_FD(hook, flags));
log_printf (" error . . . . . . . . : %d", HOOK_FD(hook, error));
diff --git a/src/core/hook/hook-focus.c b/src/core/hook/hook-focus.c
index 8731709b6..53f42785b 100644
--- a/src/core/hook/hook-focus.c
+++ b/src/core/hook/hook-focus.c
@@ -331,6 +331,6 @@ hook_focus_print_log (struct t_hook *hook)
return;
log_printf (" focus data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_FOCUS(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_FOCUS(hook, callback));
log_printf (" area. . . . . . . . . : '%s'", HOOK_FOCUS(hook, area));
}
diff --git a/src/core/hook/hook-hdata.c b/src/core/hook/hook-hdata.c
index 2ba924e47..a1d98672f 100644
--- a/src/core/hook/hook-hdata.c
+++ b/src/core/hook/hook-hdata.c
@@ -215,7 +215,7 @@ hook_hdata_print_log (struct t_hook *hook)
return;
log_printf (" hdata data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_HDATA(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_HDATA(hook, callback));
log_printf (" hdata_name. . . . . . : '%s'", HOOK_HDATA(hook, hdata_name));
log_printf (" description . . . . . : '%s'", HOOK_HDATA(hook, description));
}
diff --git a/src/core/hook/hook-hsignal.c b/src/core/hook/hook-hsignal.c
index cffd5e031..235bf37dc 100644
--- a/src/core/hook/hook-hsignal.c
+++ b/src/core/hook/hook-hsignal.c
@@ -233,7 +233,7 @@ hook_hsignal_print_log (struct t_hook *hook)
return;
log_printf (" signal data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_HSIGNAL(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_HSIGNAL(hook, callback));
log_printf (" signals:");
for (i = 0; i < HOOK_HSIGNAL(hook, num_signals); i++)
{
diff --git a/src/core/hook/hook-info-hashtable.c b/src/core/hook/hook-info-hashtable.c
index 72d808bf3..bbe12e462 100644
--- a/src/core/hook/hook-info-hashtable.c
+++ b/src/core/hook/hook-info-hashtable.c
@@ -237,7 +237,7 @@ hook_info_hashtable_print_log (struct t_hook *hook)
return;
log_printf (" info_hashtable data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_INFO_HASHTABLE(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_INFO_HASHTABLE(hook, callback));
log_printf (" info_name . . . . . . : '%s'", HOOK_INFO_HASHTABLE(hook, info_name));
log_printf (" description . . . . . : '%s'", HOOK_INFO_HASHTABLE(hook, description));
log_printf (" args_description. . . : '%s'", HOOK_INFO_HASHTABLE(hook, args_description));
diff --git a/src/core/hook/hook-info.c b/src/core/hook/hook-info.c
index 498dcf9f7..c63e8e4be 100644
--- a/src/core/hook/hook-info.c
+++ b/src/core/hook/hook-info.c
@@ -221,7 +221,7 @@ void
hook_info_print_log (struct t_hook *hook)
{
log_printf (" info data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_INFO(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_INFO(hook, callback));
log_printf (" info_name . . . . . . : '%s'", HOOK_INFO(hook, info_name));
log_printf (" description . . . . . : '%s'", HOOK_INFO(hook, description));
log_printf (" args_description. . . : '%s'", HOOK_INFO(hook, args_description));
diff --git a/src/core/hook/hook-infolist.c b/src/core/hook/hook-infolist.c
index 4482cfa75..d8ffab1ee 100644
--- a/src/core/hook/hook-infolist.c
+++ b/src/core/hook/hook-infolist.c
@@ -238,7 +238,7 @@ hook_infolist_print_log (struct t_hook *hook)
return;
log_printf (" infolist data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_INFOLIST(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_INFOLIST(hook, callback));
log_printf (" infolist_name . . . . : '%s'", HOOK_INFOLIST(hook, infolist_name));
log_printf (" description . . . . . : '%s'", HOOK_INFOLIST(hook, description));
log_printf (" pointer_description . : '%s'", HOOK_INFOLIST(hook, pointer_description));
diff --git a/src/core/hook/hook-line.c b/src/core/hook/hook-line.c
index a8ec86a7f..cea6f7afa 100644
--- a/src/core/hook/hook-line.c
+++ b/src/core/hook/hook-line.c
@@ -279,9 +279,9 @@ hook_line_print_log (struct t_hook *hook)
return;
log_printf (" line data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_LINE(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_LINE(hook, callback));
log_printf (" buffer_type . . . . . : %d", HOOK_LINE(hook, buffer_type));
- log_printf (" buffers . . . . . . . : 0x%lx", HOOK_LINE(hook, buffers));
+ log_printf (" buffers . . . . . . . : %p", HOOK_LINE(hook, buffers));
log_printf (" num_buffers . . . . . : %d", HOOK_LINE(hook, num_buffers));
for (i = 0; i < HOOK_LINE(hook, num_buffers); i++)
{
@@ -289,7 +289,7 @@ hook_line_print_log (struct t_hook *hook)
i, HOOK_LINE(hook, buffers)[i]);
}
log_printf (" tags_count. . . . . . : %d", HOOK_LINE(hook, tags_count));
- log_printf (" tags_array. . . . . . : 0x%lx", HOOK_LINE(hook, tags_array));
+ log_printf (" tags_array. . . . . . : %p", HOOK_LINE(hook, tags_array));
if (HOOK_LINE(hook, tags_array))
{
for (i = 0; i < HOOK_LINE(hook, tags_count); i++)
diff --git a/src/core/hook/hook-modifier.c b/src/core/hook/hook-modifier.c
index feac9a064..e8efbc557 100644
--- a/src/core/hook/hook-modifier.c
+++ b/src/core/hook/hook-modifier.c
@@ -213,6 +213,6 @@ hook_modifier_print_log (struct t_hook *hook)
return;
log_printf (" modifier data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_MODIFIER(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_MODIFIER(hook, callback));
log_printf (" modifier. . . . . . . : '%s'", HOOK_MODIFIER(hook, modifier));
}
diff --git a/src/core/hook/hook-print.c b/src/core/hook/hook-print.c
index 54b55fdff..d04cfdad3 100644
--- a/src/core/hook/hook-print.c
+++ b/src/core/hook/hook-print.c
@@ -257,10 +257,10 @@ hook_print_print_log (struct t_hook *hook)
return;
log_printf (" print data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_PRINT(hook, callback));
- log_printf (" buffer. . . . . . . . : 0x%lx", HOOK_PRINT(hook, buffer));
+ log_printf (" callback. . . . . . . : %p", HOOK_PRINT(hook, callback));
+ log_printf (" buffer. . . . . . . . : %p", HOOK_PRINT(hook, buffer));
log_printf (" tags_count. . . . . . : %d", HOOK_PRINT(hook, tags_count));
- log_printf (" tags_array. . . . . . : 0x%lx", HOOK_PRINT(hook, tags_array));
+ log_printf (" tags_array. . . . . . : %p", HOOK_PRINT(hook, tags_array));
if (HOOK_PRINT(hook, tags_array))
{
for (i = 0; i < HOOK_PRINT(hook, tags_count); i++)
diff --git a/src/core/hook/hook-process.c b/src/core/hook/hook-process.c
index 44668ba92..cb64d2375 100644
--- a/src/core/hook/hook-process.c
+++ b/src/core/hook/hook-process.c
@@ -978,9 +978,9 @@ hook_process_print_log (struct t_hook *hook)
return;
log_printf (" process data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_PROCESS(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_PROCESS(hook, callback));
log_printf (" command . . . . . . . : '%s'", HOOK_PROCESS(hook, command));
- log_printf (" options . . . . . . . : 0x%lx (hashtable: '%s')",
+ log_printf (" options . . . . . . . : %p (hashtable: '%s')",
HOOK_PROCESS(hook, options),
hashtable_get_string (HOOK_PROCESS(hook, options),
"keys_values"));
@@ -993,8 +993,8 @@ hook_process_print_log (struct t_hook *hook)
log_printf (" child_read[stderr]. . : %d", HOOK_PROCESS(hook, child_read[HOOK_PROCESS_STDERR]));
log_printf (" child_write[stderr] . : %d", HOOK_PROCESS(hook, child_write[HOOK_PROCESS_STDERR]));
log_printf (" child_pid . . . . . . : %d", HOOK_PROCESS(hook, child_pid));
- log_printf (" hook_fd[stdin]. . . . : 0x%lx", HOOK_PROCESS(hook, hook_fd[HOOK_PROCESS_STDIN]));
- log_printf (" hook_fd[stdout] . . . : 0x%lx", HOOK_PROCESS(hook, hook_fd[HOOK_PROCESS_STDOUT]));
- log_printf (" hook_fd[stderr] . . . : 0x%lx", HOOK_PROCESS(hook, hook_fd[HOOK_PROCESS_STDERR]));
- log_printf (" hook_timer. . . . . . : 0x%lx", HOOK_PROCESS(hook, hook_timer));
+ log_printf (" hook_fd[stdin]. . . . : %p", HOOK_PROCESS(hook, hook_fd[HOOK_PROCESS_STDIN]));
+ log_printf (" hook_fd[stdout] . . . : %p", HOOK_PROCESS(hook, hook_fd[HOOK_PROCESS_STDOUT]));
+ log_printf (" hook_fd[stderr] . . . : %p", HOOK_PROCESS(hook, hook_fd[HOOK_PROCESS_STDERR]));
+ log_printf (" hook_timer. . . . . . : %p", HOOK_PROCESS(hook, hook_timer));
}
diff --git a/src/core/hook/hook-signal.c b/src/core/hook/hook-signal.c
index 837db2e67..a9c1b3e83 100644
--- a/src/core/hook/hook-signal.c
+++ b/src/core/hook/hook-signal.c
@@ -234,7 +234,7 @@ hook_signal_print_log (struct t_hook *hook)
return;
log_printf (" signal data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_SIGNAL(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_SIGNAL(hook, callback));
log_printf (" signals:");
for (i = 0; i < HOOK_SIGNAL(hook, num_signals); i++)
{
diff --git a/src/core/hook/hook-timer.c b/src/core/hook/hook-timer.c
index 1fd9dd3c5..15e432c5c 100644
--- a/src/core/hook/hook-timer.c
+++ b/src/core/hook/hook-timer.c
@@ -421,7 +421,7 @@ hook_timer_print_log (struct t_hook *hook)
return;
log_printf (" timer data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_TIMER(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_TIMER(hook, callback));
log_printf (" interval. . . . . . . : %ld", HOOK_TIMER(hook, interval));
log_printf (" align_second. . . . . : %d", HOOK_TIMER(hook, align_second));
log_printf (" remaining_calls . . . : %d", HOOK_TIMER(hook, remaining_calls));
diff --git a/src/core/hook/hook-url.c b/src/core/hook/hook-url.c
index 19cef8c37..aa33d0cce 100644
--- a/src/core/hook/hook-url.c
+++ b/src/core/hook/hook-url.c
@@ -444,17 +444,17 @@ hook_url_print_log (struct t_hook *hook)
return;
log_printf (" url data:");
- log_printf (" callback. . . . . . . : 0x%lx", HOOK_URL(hook, callback));
+ log_printf (" callback. . . . . . . : %p", HOOK_URL(hook, callback));
log_printf (" url . . . . . . . . . : '%s'", HOOK_URL(hook, url));
- log_printf (" options . . . . . . . : 0x%lx (hashtable: '%s')",
+ log_printf (" options . . . . . . . : %p (hashtable: '%s')",
HOOK_URL(hook, options),
hashtable_get_string (HOOK_URL(hook, options),
"keys_values"));
log_printf (" timeout . . . . . . . : %ld", HOOK_URL(hook, timeout));
log_printf (" thread_created. . . . : %d", (int)HOOK_URL(hook, thread_created));
log_printf (" thread_running. . . . : %d", (int)HOOK_URL(hook, thread_running));
- log_printf (" hook_timer. . . . . . : 0x%lx", HOOK_URL(hook, hook_timer));
- log_printf (" output. . . . . . . . : 0x%lx (hashtable: '%s')",
+ log_printf (" hook_timer. . . . . . : %p", HOOK_URL(hook, hook_timer));
+ log_printf (" output. . . . . . . . : %p (hashtable: '%s')",
HOOK_URL(hook, output),
hashtable_get_string (HOOK_URL(hook, output),
"keys_values"));