From 551ed34ba7d8ee22d992cba3f8eddd0cc3009dc1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Franti=C5=A1ek=20Dvo=C5=99=C3=A1k?= Date: Thu, 31 May 2007 16:00:55 +0000 Subject: [PATCH] Various patches for WS interface in glite 3.0. Fixes bug #26811. --- org.glite.lb.server/examples/ws_getversion.c | 1 + org.glite.lb.server/examples/ws_joblog.c | 1 + org.glite.lb.server/examples/ws_jobstat.c | 1 + org.glite.lb.server/examples/ws_query_ex.c | 2 +- org.glite.lb.server/src/ws_typeref.c.T | 4 ++-- 5 files changed, 6 insertions(+), 3 deletions(-) diff --git a/org.glite.lb.server/examples/ws_getversion.c b/org.glite.lb.server/examples/ws_getversion.c index 6396650..8560cfb 100644 --- a/org.glite.lb.server/examples/ws_getversion.c +++ b/org.glite.lb.server/examples/ws_getversion.c @@ -49,6 +49,7 @@ int main(int argc,char** argv) glite_gsplugin_init_context(&gsplugin_ctx); soap_init(&soap); + soap_set_namespaces(&soap, namespaces); if ( soap_register_plugin_arg(&soap, glite_gsplugin, (void *)gsplugin_ctx) ) { diff --git a/org.glite.lb.server/examples/ws_joblog.c b/org.glite.lb.server/examples/ws_joblog.c index 9b6d267..e197df0 100644 --- a/org.glite.lb.server/examples/ws_joblog.c +++ b/org.glite.lb.server/examples/ws_joblog.c @@ -77,6 +77,7 @@ int main(int argc,char** argv) edg_wll_InitContext(&ctx); glite_gsplugin_init_context(&gsplugin_ctx); + soap_set_namespaces(mydlo, namespaces); if ( soap_register_plugin_arg(mydlo, glite_gsplugin, (void *)gsplugin_ctx) ) { soap_print_fault(mydlo, stderr); diff --git a/org.glite.lb.server/examples/ws_jobstat.c b/org.glite.lb.server/examples/ws_jobstat.c index 603d9c7..f38c94f 100644 --- a/org.glite.lb.server/examples/ws_jobstat.c +++ b/org.glite.lb.server/examples/ws_jobstat.c @@ -65,6 +65,7 @@ int main(int argc,char** argv) } edg_wll_InitContext(&ctx); + soap_set_namespaces(mydlo, namespaces); glite_gsplugin_init_context(&gsplugin_ctx); if ( soap_register_plugin_arg(mydlo, glite_gsplugin, (void *)gsplugin_ctx) ) diff --git a/org.glite.lb.server/examples/ws_query_ex.c b/org.glite.lb.server/examples/ws_query_ex.c index aae1624..2f3bd62 100644 --- a/org.glite.lb.server/examples/ws_query_ex.c +++ b/org.glite.lb.server/examples/ws_query_ex.c @@ -50,7 +50,7 @@ int main(int argc,char** argv) edg_wll_InitContext(&ctx); glite_gsplugin_init_context(&gsplugin_ctx); - + soap_set_namespaces(soap, namespaces); if ( soap_register_plugin_arg(soap, glite_gsplugin, (void *)gsplugin_ctx) ) { soap_print_fault(soap, stderr); diff --git a/org.glite.lb.server/src/ws_typeref.c.T b/org.glite.lb.server/src/ws_typeref.c.T index 90b40f6..5853f2a 100644 --- a/org.glite.lb.server/src/ws_typeref.c.T +++ b/org.glite.lb.server/src/ws_typeref.c.T @@ -603,7 +603,7 @@ int edg_wll_QueryCondsToSoap( } qc->__sizerecord = 0; - while ( in[qc->__sizerecord++].attr ); + while ( in[qc->__sizerecord].attr ) qc->__sizerecord++; if ( !qc->__sizerecord ) goto ret; @@ -633,7 +633,7 @@ int edg_wll_SoapToQueryCondsExt(const struct lbt__queryConditions **in, int __si edg_wll_QueryRec **qr; assert(out); - if ( !(qr = calloc(__sizecondition, sizeof(*qr))) ) return -1; + if ( !(qr = calloc(__sizecondition + 1, sizeof(*qr))) ) return -1; for ( i = 0; i < __sizecondition; i++ ) if ( edg_wll_SoapToQueryConds(in[i], qr+i) ) goto err; -- 1.8.2.3