diff options
| -rw-r--r-- | lasso/xml/lib_status_response.c | 11 | ||||
| -rw-r--r-- | lasso/xml/samlp_status_code.c | 18 |
2 files changed, 11 insertions, 18 deletions
diff --git a/lasso/xml/lib_status_response.c b/lasso/xml/lib_status_response.c index 6a75b2da..883a52ca 100644 --- a/lasso/xml/lib_status_response.c +++ b/lasso/xml/lib_status_response.c @@ -96,6 +96,17 @@ init_from_query(LassoNode *node, char **query_fields) if (response->ProviderID == NULL || response->Status == NULL) return FALSE; + if (response->Status->StatusCode) { + LassoSamlpStatusCode *code = response->Status->StatusCode; + if (code->Value && strchr(code->Value, ':') == NULL) { + char *s; /* if not a QName; add the samlp prefix */ + s = g_strdup_printf("samlp:%s", code->Value); + g_free(code->Value); + code->Value = s; + } + } + + return TRUE; } diff --git a/lasso/xml/samlp_status_code.c b/lasso/xml/samlp_status_code.c index 1952f37b..f2d8d9fb 100644 --- a/lasso/xml/samlp_status_code.c +++ b/lasso/xml/samlp_status_code.c @@ -47,23 +47,6 @@ static struct XmlSnippet schema_snippets[] = { { NULL, 0, 0} }; -static gboolean -init_from_query(LassoNode *node, char **query_fields) -{ - LassoSamlpStatusCode *code = LASSO_SAMLP_STATUS_CODE(node); - gboolean rc; - - rc = lasso_node_init_from_query_fields(node, query_fields); - if (code->Value && strchr(code->Value, ':') == NULL) { - char *s; /* if not a QName; add the samlp prefix */ - s = g_strdup_printf("samlp:%s", code->Value); - g_free(code->Value); - code->Value = s; - } - - return rc; -} - /*****************************************************************************/ /* instance and class init functions */ /*****************************************************************************/ @@ -80,7 +63,6 @@ class_init(LassoSamlpStatusCodeClass *klass) LassoNodeClass *nclass = LASSO_NODE_CLASS(klass); nclass->node_data = g_new0(LassoNodeClassData, 1); - nclass->init_from_query = init_from_query; lasso_node_class_set_nodename(nclass, "StatusCode"); lasso_node_class_set_ns(nclass, LASSO_SAML_PROTOCOL_HREF, LASSO_SAML_PROTOCOL_PREFIX); lasso_node_class_add_snippets(nclass, schema_snippets); |
