aboutsummaryrefslogtreecommitdiff
path: root/packages/OS400/ccsidcurl.c
diff options
context:
space:
mode:
Diffstat (limited to 'packages/OS400/ccsidcurl.c')
-rw-r--r--packages/OS400/ccsidcurl.c39
1 files changed, 39 insertions, 0 deletions
diff --git a/packages/OS400/ccsidcurl.c b/packages/OS400/ccsidcurl.c
index a903fe34a..7b7607130 100644
--- a/packages/OS400/ccsidcurl.c
+++ b/packages/OS400/ccsidcurl.c
@@ -1278,3 +1278,42 @@ curl_form_long_value(long value)
return (char *) value;
}
+
+
+char *
+curl_pushheader_bynum_cssid(struct curl_pushheaders *h,
+ size_t num, unsigned int ccsid)
+
+{
+ char *d = (char *) NULL;
+ char *s = curl_pushheader_bynum(h, num);
+
+ if(s)
+ d = dynconvert(ccsid, s, -1, ASCII_CCSID);
+
+ return d;
+}
+
+
+char *
+curl_pushheader_byname_ccsid(struct curl_pushheaders *h, const char *header,
+ unsigned int ccsidin, unsigned int ccsidout)
+
+{
+ char *d = (char *) NULL;
+ char *s;
+
+ if(header) {
+ header = dynconvert(ASCII_CCSID, header, -1, ccsidin);
+
+ if(header) {
+ s = curl_pushheader_byname(h, header);
+ free((char *) header);
+
+ if(s)
+ d = dynconvert(ccsidout, s, -1, ASCII_CCSID);
+ }
+ }
+
+ return d;
+}