summaryrefslogtreecommitdiff
path: root/content/content.c
diff options
context:
space:
mode:
authorJames Bursa <james@netsurf-browser.org>2005-08-21 12:04:18 +0000
committerJames Bursa <james@netsurf-browser.org>2005-08-21 12:04:18 +0000
commit08e8ee3ed19642b9fbad9f3d8764a0befd7f2a58 (patch)
treeb6cf45a433bef0fd7ddab83bcb598d1c1ca31731 /content/content.c
parent4f82731104cafcc50607879957e248f0bec30e56 (diff)
downloadnetsurf-08e8ee3ed19642b9fbad9f3d8764a0befd7f2a58.tar.gz
netsurf-08e8ee3ed19642b9fbad9f3d8764a0befd7f2a58.tar.bz2
[project @ 2005-08-21 12:04:17 by bursa]
Change void * parameters to intptr_t to make them correct for storing integers or pointers. svn path=/import/netsurf/; revision=1852
Diffstat (limited to 'content/content.c')
-rw-r--r--content/content.c42
1 files changed, 23 insertions, 19 deletions
diff --git a/content/content.c b/content/content.c
index a8b34a6e7..1d6e32a8b 100644
--- a/content/content.c
+++ b/content/content.c
@@ -2,7 +2,7 @@
* This file is part of NetSurf, http://netsurf.sourceforge.net/
* Licensed under the GNU General Public License,
* http://www.opensource.org/licenses/gpl-license
- * Copyright 2004 James Bursa <bursa@users.sourceforge.net>
+ * Copyright 2005 James Bursa <bursa@users.sourceforge.net>
*/
/** \file
@@ -13,6 +13,7 @@
*/
#include <assert.h>
+#include <inttypes.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
@@ -363,9 +364,9 @@ bool content_set_type(struct content *c, content_type type,
{
union content_msg_data msg_data;
struct content *clone;
- void (*callback)(content_msg msg, struct content *c, void *p1,
- void *p2, union content_msg_data data);
- void *p1, *p2;
+ void (*callback)(content_msg msg, struct content *c, intptr_t p1,
+ intptr_t p2, union content_msg_data data);
+ intptr_t p1, p2;
assert(c != 0);
assert(c->status == CONTENT_STATUS_TYPE_UNKNOWN);
@@ -772,13 +773,14 @@ bool content_redraw(struct content *c, int x, int y,
*/
bool content_add_user(struct content *c,
- void (*callback)(content_msg msg, struct content *c, void *p1,
- void *p2, union content_msg_data data),
- void *p1, void *p2)
+ void (*callback)(content_msg msg, struct content *c,
+ intptr_t p1, intptr_t p2, union content_msg_data data),
+ intptr_t p1, intptr_t p2)
{
struct content_user *user;
- LOG(("content %s, user %p %p %p", c->url, callback, p1, p2));
+ LOG(("content %s, user %p 0x%" PRIxPTR " 0x%" PRIxPTR,
+ c->url, callback, p1, p2));
user = talloc(c, struct content_user);
if (!user)
return false;
@@ -800,9 +802,9 @@ bool content_add_user(struct content *c,
*/
struct content_user * content_find_user(struct content *c,
- void (*callback)(content_msg msg, struct content *c, void *p1,
- void *p2, union content_msg_data data),
- void *p1, void *p2)
+ void (*callback)(content_msg msg, struct content *c,
+ intptr_t p1, intptr_t p2, union content_msg_data data),
+ intptr_t p1, intptr_t p2)
{
struct content_user *user;
@@ -824,12 +826,13 @@ struct content_user * content_find_user(struct content *c,
*/
void content_remove_user(struct content *c,
- void (*callback)(content_msg msg, struct content *c, void *p1,
- void *p2, union content_msg_data data),
- void *p1, void *p2)
+ void (*callback)(content_msg msg, struct content *c,
+ intptr_t p1, intptr_t p2, union content_msg_data data),
+ intptr_t p1, intptr_t p2)
{
struct content_user *user, *next;
- LOG(("content %s, user %p %p %p", c->url, callback, p1, p2));
+ LOG(("content %s, user %p 0x%" PRIxPTR " 0x%" PRIxPTR,
+ c->url, callback, p1, p2));
/* user_list starts with a sentinel */
for (user = c->user_list; user->next != 0 &&
@@ -873,9 +876,9 @@ void content_broadcast(struct content *c, content_msg msg,
*/
void content_stop(struct content *c,
- void (*callback)(content_msg msg, struct content *c, void *p1,
- void *p2, union content_msg_data data),
- void *p1, void *p2)
+ void (*callback)(content_msg msg, struct content *c,
+ intptr_t p1, intptr_t p2, union content_msg_data data),
+ intptr_t p1, intptr_t p2)
{
struct content_user *user;
@@ -888,7 +891,8 @@ void content_stop(struct content *c,
return;
}
- LOG(("%p %s: stop user %p %p %p", c, c->url, callback, p1, p2));
+ LOG(("%p %s: stop user %p 0x%" PRIxPTR " 0x%" PRIxPTR,
+ c, c->url, callback, p1, p2));
user->stop = true;
}