summaryrefslogtreecommitdiff
path: root/src/include/taler_wire_plugin.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2016-11-18 18:29:18 +0100
committerChristian Grothoff <christian@grothoff.org>2016-11-18 18:29:18 +0100
commit7d6b8d53d5a6ee6ca1545fb5d458199c6249edc5 (patch)
treef44f7afb792184ef46e6d4882cb20de0e2d8b519 /src/include/taler_wire_plugin.h
parentde68a7b301fd78a89c4f5e6f34791c8debab36e0 (diff)
downloadexchange-7d6b8d53d5a6ee6ca1545fb5d458199c6249edc5.tar.gz
exchange-7d6b8d53d5a6ee6ca1545fb5d458199c6249edc5.tar.bz2
exchange-7d6b8d53d5a6ee6ca1545fb5d458199c6249edc5.zip
addressing #4803: nicer error messages for invalid wire formats
Diffstat (limited to 'src/include/taler_wire_plugin.h')
-rw-r--r--src/include/taler_wire_plugin.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/include/taler_wire_plugin.h b/src/include/taler_wire_plugin.h
index c3c9c3a54..6c06e8247 100644
--- a/src/include/taler_wire_plugin.h
+++ b/src/include/taler_wire_plugin.h
@@ -24,6 +24,7 @@
#include <gnunet/gnunet_util_lib.h>
#include <jansson.h>
#include "taler_util.h"
+#include "taler_error_codes.h"
/**
@@ -137,12 +138,15 @@ struct TALER_WIRE_Plugin
* @param cls the @e cls of this struct with the plugin-specific state
* @param wire the JSON wire format object
* @param master_pub public key of the exchange to verify against
- * @return #GNUNET_YES if correctly formatted; #GNUNET_NO if not
+ * @param[OUT] emsg set to an error message, unless we return #TALER_EC_NONE;
+ * error message must be freed by the caller using GNUNET_free()
+ * @return #TALER_EC_NONE if correctly formatted
*/
- int
+ enum TALER_ErrorCode
(*wire_validate) (void *cls,
const json_t *wire,
- const struct TALER_MasterPublicKeyP *master_pub);
+ const struct TALER_MasterPublicKeyP *master_pub,
+ char **emsg);
/**