diff options
author | Christian Grothoff <christian@grothoff.org> | 2010-10-06 11:44:29 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2010-10-06 11:44:29 +0000 |
commit | b8da6057b2c0c66931ccde9b4bba418fc5222724 (patch) | |
tree | 1e858619686d7e2d38655f9f24bdc64e3e4e8462 /src/datacache | |
parent | 7d2cbe5bd19ec95ada5a28a0134185ef29007b69 (diff) | |
download | gnunet-b8da6057b2c0c66931ccde9b4bba418fc5222724.tar.gz gnunet-b8da6057b2c0c66931ccde9b4bba418fc5222724.zip |
use size_t
Diffstat (limited to 'src/datacache')
-rw-r--r-- | src/datacache/datacache.c | 4 | ||||
-rw-r--r-- | src/datacache/perf_datacache.c | 2 | ||||
-rw-r--r-- | src/datacache/plugin_datacache.h | 14 | ||||
-rw-r--r-- | src/datacache/plugin_datacache_mysql.c | 4 | ||||
-rw-r--r-- | src/datacache/plugin_datacache_postgres.c | 4 | ||||
-rw-r--r-- | src/datacache/plugin_datacache_sqlite.c | 4 | ||||
-rw-r--r-- | src/datacache/plugin_datacache_template.c | 4 | ||||
-rw-r--r-- | src/datacache/test_datacache.c | 2 |
8 files changed, 19 insertions, 19 deletions
diff --git a/src/datacache/datacache.c b/src/datacache/datacache.c index 9c1a90bca..d2aa2616a 100644 --- a/src/datacache/datacache.c +++ b/src/datacache/datacache.c | |||
@@ -100,7 +100,7 @@ struct GNUNET_DATACACHE_Handle | |||
100 | static void | 100 | static void |
101 | env_delete_notify (void *cls, | 101 | env_delete_notify (void *cls, |
102 | const GNUNET_HashCode *key, | 102 | const GNUNET_HashCode *key, |
103 | uint32_t size) | 103 | size_t size) |
104 | { | 104 | { |
105 | struct GNUNET_DATACACHE_Handle * h = cls; | 105 | struct GNUNET_DATACACHE_Handle * h = cls; |
106 | GNUNET_assert (h->utilization >= size); | 106 | GNUNET_assert (h->utilization >= size); |
@@ -237,7 +237,7 @@ void GNUNET_DATACACHE_destroy (struct GNUNET_DATACACHE_Handle *h) | |||
237 | int | 237 | int |
238 | GNUNET_DATACACHE_put (struct GNUNET_DATACACHE_Handle *h, | 238 | GNUNET_DATACACHE_put (struct GNUNET_DATACACHE_Handle *h, |
239 | const GNUNET_HashCode * key, | 239 | const GNUNET_HashCode * key, |
240 | uint32_t size, | 240 | size_t size, |
241 | const char *data, | 241 | const char *data, |
242 | enum GNUNET_BLOCK_Type type, | 242 | enum GNUNET_BLOCK_Type type, |
243 | struct GNUNET_TIME_Absolute discard_time) | 243 | struct GNUNET_TIME_Absolute discard_time) |
diff --git a/src/datacache/perf_datacache.c b/src/datacache/perf_datacache.c index 10efa5eee..023199231 100644 --- a/src/datacache/perf_datacache.c +++ b/src/datacache/perf_datacache.c | |||
@@ -46,7 +46,7 @@ static int | |||
46 | checkIt (void *cls, | 46 | checkIt (void *cls, |
47 | struct GNUNET_TIME_Absolute exp, | 47 | struct GNUNET_TIME_Absolute exp, |
48 | const GNUNET_HashCode * key, | 48 | const GNUNET_HashCode * key, |
49 | uint32_t size, | 49 | size_t size, |
50 | const char *data, | 50 | const char *data, |
51 | enum GNUNET_BLOCK_Type type) | 51 | enum GNUNET_BLOCK_Type type) |
52 | { | 52 | { |
diff --git a/src/datacache/plugin_datacache.h b/src/datacache/plugin_datacache.h index c7360834b..bf35b2619 100644 --- a/src/datacache/plugin_datacache.h +++ b/src/datacache/plugin_datacache.h | |||
@@ -47,7 +47,7 @@ extern "C" | |||
47 | */ | 47 | */ |
48 | typedef void (*GNUNET_DATACACHE_DeleteNotifyCallback)(void *cls, | 48 | typedef void (*GNUNET_DATACACHE_DeleteNotifyCallback)(void *cls, |
49 | const GNUNET_HashCode *key, | 49 | const GNUNET_HashCode *key, |
50 | uint32_t size); | 50 | size_t size); |
51 | 51 | ||
52 | 52 | ||
53 | /** | 53 | /** |
@@ -112,12 +112,12 @@ struct GNUNET_DATACACHE_PluginFunctions { | |||
112 | * @param discard_time when to discard the value in any case | 112 | * @param discard_time when to discard the value in any case |
113 | * @return 0 on error, number of bytes used otherwise | 113 | * @return 0 on error, number of bytes used otherwise |
114 | */ | 114 | */ |
115 | uint32_t (*put) (void *cls, | 115 | size_t (*put) (void *cls, |
116 | const GNUNET_HashCode * key, | 116 | const GNUNET_HashCode * key, |
117 | uint32_t size, | 117 | size_t size, |
118 | const char *data, | 118 | const char *data, |
119 | enum GNUNET_BLOCK_Type type, | 119 | enum GNUNET_BLOCK_Type type, |
120 | struct GNUNET_TIME_Absolute discard_time); | 120 | struct GNUNET_TIME_Absolute discard_time); |
121 | 121 | ||
122 | 122 | ||
123 | /** | 123 | /** |
diff --git a/src/datacache/plugin_datacache_mysql.c b/src/datacache/plugin_datacache_mysql.c index a85e9f480..8241fb5f8 100644 --- a/src/datacache/plugin_datacache_mysql.c +++ b/src/datacache/plugin_datacache_mysql.c | |||
@@ -721,10 +721,10 @@ itable (struct Plugin *plugin) | |||
721 | * @param discard_time when to discard the value in any case | 721 | * @param discard_time when to discard the value in any case |
722 | * @return 0 on error, number of bytes used otherwise | 722 | * @return 0 on error, number of bytes used otherwise |
723 | */ | 723 | */ |
724 | static uint32_t | 724 | static size_t |
725 | mysql_plugin_put (void *cls, | 725 | mysql_plugin_put (void *cls, |
726 | const GNUNET_HashCode * key, | 726 | const GNUNET_HashCode * key, |
727 | uint32_t size, | 727 | size_t size, |
728 | const char *data, | 728 | const char *data, |
729 | enum GNUNET_BLOCK_Type type, | 729 | enum GNUNET_BLOCK_Type type, |
730 | struct GNUNET_TIME_Absolute discard_time) | 730 | struct GNUNET_TIME_Absolute discard_time) |
diff --git a/src/datacache/plugin_datacache_postgres.c b/src/datacache/plugin_datacache_postgres.c index fcd9e5161..c9d6deaaa 100644 --- a/src/datacache/plugin_datacache_postgres.c +++ b/src/datacache/plugin_datacache_postgres.c | |||
@@ -301,10 +301,10 @@ delete_by_rowid (struct Plugin *plugin, | |||
301 | * @param discard_time when to discard the value in any case | 301 | * @param discard_time when to discard the value in any case |
302 | * @return 0 on error, number of bytes used otherwise | 302 | * @return 0 on error, number of bytes used otherwise |
303 | */ | 303 | */ |
304 | static uint32_t | 304 | static size_t |
305 | postgres_plugin_put (void *cls, | 305 | postgres_plugin_put (void *cls, |
306 | const GNUNET_HashCode * key, | 306 | const GNUNET_HashCode * key, |
307 | uint32_t size, | 307 | size_t size, |
308 | const char *data, | 308 | const char *data, |
309 | enum GNUNET_BLOCK_Type type, | 309 | enum GNUNET_BLOCK_Type type, |
310 | struct GNUNET_TIME_Absolute discard_time) | 310 | struct GNUNET_TIME_Absolute discard_time) |
diff --git a/src/datacache/plugin_datacache_sqlite.c b/src/datacache/plugin_datacache_sqlite.c index 8c144baa2..5c304bd8a 100644 --- a/src/datacache/plugin_datacache_sqlite.c +++ b/src/datacache/plugin_datacache_sqlite.c | |||
@@ -94,10 +94,10 @@ sq_prepare (sqlite3 * dbh, const char *zSql, /* SQL statement, UTF-8 encoded | |||
94 | * @param discard_time when to discard the value in any case | 94 | * @param discard_time when to discard the value in any case |
95 | * @return 0 on error, number of bytes used otherwise | 95 | * @return 0 on error, number of bytes used otherwise |
96 | */ | 96 | */ |
97 | static uint32_t | 97 | static size_t |
98 | sqlite_plugin_put (void *cls, | 98 | sqlite_plugin_put (void *cls, |
99 | const GNUNET_HashCode * key, | 99 | const GNUNET_HashCode * key, |
100 | uint32_t size, | 100 | size_t size, |
101 | const char *data, | 101 | const char *data, |
102 | enum GNUNET_BLOCK_Type type, | 102 | enum GNUNET_BLOCK_Type type, |
103 | struct GNUNET_TIME_Absolute discard_time) | 103 | struct GNUNET_TIME_Absolute discard_time) |
diff --git a/src/datacache/plugin_datacache_template.c b/src/datacache/plugin_datacache_template.c index 4ebf72661..25e4c9a42 100644 --- a/src/datacache/plugin_datacache_template.c +++ b/src/datacache/plugin_datacache_template.c | |||
@@ -51,10 +51,10 @@ struct Plugin | |||
51 | * @param discard_time when to discard the value in any case | 51 | * @param discard_time when to discard the value in any case |
52 | * @return 0 on error, number of bytes used otherwise | 52 | * @return 0 on error, number of bytes used otherwise |
53 | */ | 53 | */ |
54 | static uint32_t | 54 | static size_t |
55 | template_plugin_put (void *cls, | 55 | template_plugin_put (void *cls, |
56 | const GNUNET_HashCode * key, | 56 | const GNUNET_HashCode * key, |
57 | uint32_t size, | 57 | size_t size, |
58 | const char *data, | 58 | const char *data, |
59 | enum GNUNET_BLOCK_Type type, | 59 | enum GNUNET_BLOCK_Type type, |
60 | struct GNUNET_TIME_Absolute discard_time) | 60 | struct GNUNET_TIME_Absolute discard_time) |
diff --git a/src/datacache/test_datacache.c b/src/datacache/test_datacache.c index 0c9399aff..da7894d6b 100644 --- a/src/datacache/test_datacache.c +++ b/src/datacache/test_datacache.c | |||
@@ -42,7 +42,7 @@ static int | |||
42 | checkIt (void *cls, | 42 | checkIt (void *cls, |
43 | struct GNUNET_TIME_Absolute exp, | 43 | struct GNUNET_TIME_Absolute exp, |
44 | const GNUNET_HashCode * key, | 44 | const GNUNET_HashCode * key, |
45 | uint32_t size, | 45 | size_t size, |
46 | const char *data, | 46 | const char *data, |
47 | enum GNUNET_BLOCK_Type type) | 47 | enum GNUNET_BLOCK_Type type) |
48 | { | 48 | { |