summaryrefslogtreecommitdiffstats
path: root/lasso/xml/is_interaction_request.c
diff options
context:
space:
mode:
authorBenjamin Dauvergne <bdauvergne@entrouvert.com>2009-08-26 15:14:48 +0000
committerBenjamin Dauvergne <bdauvergne@entrouvert.com>2009-08-26 15:14:48 +0000
commitb63bc73b93255d27e784e5e1dbf99fa4e1dae76b (patch)
tree7a9feeddf10c069bf243796896d2898bee632c49 /lasso/xml/is_interaction_request.c
parent291e0c05fa91b9d8e937895da6b0f1da658cd3fc (diff)
downloadlasso-b63bc73b93255d27e784e5e1dbf99fa4e1dae76b.tar.gz
lasso-b63bc73b93255d27e784e5e1dbf99fa4e1dae76b.tar.xz
lasso-b63bc73b93255d27e784e5e1dbf99fa4e1dae76b.zip
XML: remove all useless instance_init functions
* Use Coccinelle semantic patch tool (http://coccinelle.lip6.fr/) to remove useless instance_init functions, the first patch applied was: @@ type T,V; identifier I, J; parameter list P; expression E1; @@ V instance_init(T node) { <... ( - E1 = 0; | - E1 = NULL; | - E1 = FALSE; ) ...> } It removes useless initialization to 0 (GObject already zeroes allocated objects). The second one is: @ rule1 @ type T; identifier node,fn; @@ - static void fn(T *node) { } @ rule2 extends rule1 @ typedef GType, GInstanceInitFunc; identifier type_constructor; @@ GType type_constructor() { <... - (GInstanceInitFunc)fn + NULL ...> } It removes empty instance_init functions.
Diffstat (limited to 'lasso/xml/is_interaction_request.c')
-rw-r--r--lasso/xml/is_interaction_request.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/lasso/xml/is_interaction_request.c b/lasso/xml/is_interaction_request.c
index 691b39e6..cfc08a61 100644
--- a/lasso/xml/is_interaction_request.c
+++ b/lasso/xml/is_interaction_request.c
@@ -74,18 +74,6 @@ static struct XmlSnippet schema_snippets[] = {
/* instance and class init functions */
/*****************************************************************************/
-static void
-instance_init(LassoIsInteractionRequest *node)
-{
- node->ResourceID = NULL;
- node->EncryptedResourceID = NULL;
- node->Inquiry = NULL;
- /* TODO : KeyInfo */
- node->id = NULL;
- node->language = NULL;
- node->maxInteractTime = 0;
- /* TODO : signed */
-}
static void
class_init(LassoIsInteractionRequestClass *klass)
@@ -113,7 +101,7 @@ lasso_is_interaction_request_get_type()
NULL,
sizeof(LassoIsInteractionRequest),
0,
- (GInstanceInitFunc) instance_init,
+ NULL,
NULL
};