Make parse_xml_response() method and request_body_type args const
authorDavid Woodhouse <David.Woodhouse@intel.com>
Thu, 15 Sep 2011 17:00:12 +0000 (18:00 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Thu, 15 Sep 2011 17:01:14 +0000 (18:01 +0100)
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
auth.c
http.c
openconnect-internal.h

diff --git a/auth.c b/auth.c
index 5fbdda4..9064ffd 100644 (file)
--- a/auth.c
+++ b/auth.c
@@ -301,8 +301,8 @@ static char *xmlnode_msg(xmlNode *xml_node)
  *  = 2, when form indicates that login was already successful
  */
 int parse_xml_response(struct openconnect_info *vpninfo, char *response,
-                      char *request_body, int req_len, char **method,
-                      char **request_body_type)
+                      char *request_body, int req_len, const char **method,
+                      const char **request_body_type)
 {
        struct oc_auth_form *form;
        xmlDocPtr xml_doc;
diff --git a/http.c b/http.c
index 0f18410..4ba62bb 100644 (file)
--- a/http.c
+++ b/http.c
@@ -596,8 +596,8 @@ int openconnect_obtain_cookie(struct openconnect_info *vpninfo)
        char *form_buf = NULL;
        int result, buflen;
        char request_body[2048];
-       char *request_body_type = NULL;
-       char *method = "GET";
+       const char *request_body_type = NULL;
+       const char *method = "GET";
 
  retry:
        if (form_buf) {
index bddc9a1..0a3e549 100644 (file)
@@ -275,8 +275,8 @@ int config_lookup_host(struct openconnect_info *vpninfo, const char *host);
 
 /* auth.c */
 int parse_xml_response(struct openconnect_info *vpninfo, char *response,
-                      char *request_body, int req_len, char **method,
-                      char **request_body_type);
+                      char *request_body, int req_len, const char **method,
+                      const char **request_body_type);
 
 /* http.c */
 char *openconnect_create_useragent(char *base);