aboutsummaryrefslogtreecommitdiff
path: root/src/datacache/plugin_datacache_template.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-11-13 20:05:40 +0000
committerChristian Grothoff <christian@grothoff.org>2012-11-13 20:05:40 +0000
commit4e1d85bac66209e6655f3fb4d3ddef7929f0f3fc (patch)
treedf5c5a0d972f35d741b51c3a3fc8d2298ac8b4fd /src/datacache/plugin_datacache_template.c
parent855362e698928b0a5a8f72fc6427c2ea42af4e79 (diff)
downloadgnunet-4e1d85bac66209e6655f3fb4d3ddef7929f0f3fc.tar.gz
gnunet-4e1d85bac66209e6655f3fb4d3ddef7929f0f3fc.zip
changing datacache API to separate put-paths from data (so that plugins can test for duplicates), removing support for MySQL
Diffstat (limited to 'src/datacache/plugin_datacache_template.c')
-rw-r--r--src/datacache/plugin_datacache_template.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/datacache/plugin_datacache_template.c b/src/datacache/plugin_datacache_template.c
index 6c4395982..306615571 100644
--- a/src/datacache/plugin_datacache_template.c
+++ b/src/datacache/plugin_datacache_template.c
@@ -49,15 +49,19 @@ struct Plugin
49 * @param data data to store 49 * @param data data to store
50 * @param type type of the value 50 * @param type type of the value
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 * @param path_info_len number of entries in 'path_info'
53 * @param path_info a path through the network
54 * @return 0 if duplicate, -1 on error, number of bytes used otherwise
53 */ 55 */
54static size_t 56static ssize_t
55template_plugin_put (void *cls, const struct GNUNET_HashCode * key, size_t size, 57template_plugin_put (void *cls, const struct GNUNET_HashCode * key, size_t size,
56 const char *data, enum GNUNET_BLOCK_Type type, 58 const char *data, enum GNUNET_BLOCK_Type type,
57 struct GNUNET_TIME_Absolute discard_time) 59 struct GNUNET_TIME_Absolute discard_time,
60 unsigned int path_info_len,
61 const struct GNUNET_PeerIdentity *path_info)
58{ 62{
59 GNUNET_break (0); 63 GNUNET_break (0);
60 return 0; 64 return -1;
61} 65}
62 66
63 67