diff options
author | Liang Hou <houliang@intel.com> | 2007-12-12 03:25:36 +0000 |
---|---|---|
committer | Liang Hou <houliang@intel.com> | 2007-12-12 03:25:36 +0000 |
commit | 237f6a8028acf724035afdab4ffac87cf42f1c6e (patch) | |
tree | 73ba01dfce736213bcb47bff66dd1f6a1bc75d4b /src | |
parent | 0c759ef18258b8a89fedf07cf2ff6478f51020f2 (diff) | |
download | wsmancli-237f6a8028acf724035afdab4ffac87cf42f1c6e.tar.gz wsmancli-237f6a8028acf724035afdab4ffac87cf42f1c6e.tar.xz wsmancli-237f6a8028acf724035afdab4ffac87cf42f1c6e.zip |
update for internal implementation change of wsmc_action_unsubscribe/wsmc_action_renew
Diffstat (limited to 'src')
-rw-r--r-- | src/wsman.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/wsman.c b/src/wsman.c index c0cfba8..b3f6bb2 100644 --- a/src/wsman.c +++ b/src/wsman.c @@ -503,7 +503,7 @@ int main(int argc, char **argv) *resource_uri_with_selectors; char *event_mode, *delivery_uri; char *resource_uri = NULL; - + char subscontext[512]; filename = (char *) config_file; if (filename) { ini = iniparser_new(filename); @@ -814,7 +814,10 @@ int main(int argc, char **argv) } break; case WSMAN_ACTION_UNSUBSCRIBE: - rqstDoc = wsmc_action_unsubscribe(cl, resource_uri, options, event_subscription_id); + snprintf(subscontext, 512 , "<?xml version=\"1.0\" encoding=\"UTF-8\"?><wsa:ReferenceParameters xmlns:wsa=\"http://schemas.xmlsoap.org/ws/2004/08/addressing\" \ + xmlns:wse=\"http://schemas.xmlsoap.org/ws/2004/08/eventing\"><wse:Identifier>%s</wse:Identifier> \ + </wsa:ReferenceParameters>", event_subscription_id); + rqstDoc = wsmc_action_unsubscribe(cl, resource_uri, options, subscontext); wsman_output(cl, rqstDoc); if (rqstDoc) { ws_xml_destroy_doc(rqstDoc); @@ -823,6 +826,9 @@ int main(int argc, char **argv) case WSMAN_ACTION_RENEW: if(event_subscription_expire) options->expires = event_subscription_expire; + snprintf(subscontext, 512 , "<wsa:ReferenceParameters xmlns:wsa=\"http://schemas.xmlsoap.org/ws/2004/08/addressing\" \ + xmlns:wse=\"http://schemas.xmlsoap.org/ws/2004/08/eventing\"><wse:Identifier>%s</wse:Identifier> \ + </wsa:ReferenceParameters>", event_subscription_id); rqstDoc = wsmc_action_renew(cl, resource_uri, options, event_subscription_id); wsman_output(cl, rqstDoc); if (rqstDoc) { |