Skip to content

Commit e2d1154

Browse files
authored
Upgrade: xmlrpc-c version to 1.60.04 (microsoft#11243)
1 parent 9202323 commit e2d1154

File tree

6 files changed

+276
-332
lines changed

6 files changed

+276
-332
lines changed

SPECS-EXTENDED/xmlrpc-c/0001-xmlrpc_server_abyss-use-va_args-properly.patch

Lines changed: 0 additions & 34 deletions
This file was deleted.
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
From aca713786debd68c81a823c5989afb3de82da45b Mon Sep 17 00:00:00 2001
2+
From: Enrico Scholz <[email protected]>
3+
Date: Sat, 5 Apr 2008 11:41:34 +0200
4+
Subject: [PATCH 2/3] Use proper datatypes for 'long long'
5+
6+
xmlrpc-c uses 'long long' at some places (e.g. in printf
7+
statements with PRId64) under the assumption that it has a
8+
width of exactly 64 bits.
9+
10+
On 64 bit machines 'long long' has a width of 128 bit and
11+
will cause overhead both in memory and cpu usage there. As
12+
'long long' is used only to handle <i8> datatypes, the patch
13+
uses a plain 64 integer type there.
14+
15+
It is arguable whether 'int_least64_t' (and 'int_least32_t')
16+
would be a better choice for 'int64_t' (and 'int32_t'), but
17+
for now, the patch uses datatypes with exact widths.
18+
---
19+
include/xmlrpc-c/base.h | 7 ++++---
20+
lib/libutil/string_number.c | 1 +
21+
src/cpp/param_list.cpp | 2 +-
22+
3 files changed, 6 insertions(+), 4 deletions(-)
23+
24+
diff --git a/include/xmlrpc-c/base.h b/include/xmlrpc-c/base.h
25+
index e74e2c5..90f2c91 100644
26+
--- a/include/xmlrpc-c/base.h
27+
+++ b/include/xmlrpc-c/base.h
28+
@@ -5,6 +5,7 @@
29+
30+
#include <stddef.h>
31+
#include <stdarg.h>
32+
+#include <stdint.h>
33+
#include <time.h>
34+
#include <xmlrpc-c/c_util.h> /* For XMLRPC_DLLEXPORT */
35+
#include <xmlrpc-c/util.h>
36+
@@ -73,9 +74,9 @@ xmlrpc_version(unsigned int * const majorP,
37+
38+
typedef signed int xmlrpc_int;
39+
/* An integer of the type defined by XML-RPC <int>; i.e. 32 bit */
40+
-typedef XMLRPC_INT32 xmlrpc_int32;
41+
+typedef int32_t xmlrpc_int32;
42+
/* An integer of the type defined by XML-RPC <i4>; i.e. 32 bit */
43+
-typedef XMLRPC_INT64 xmlrpc_int64;
44+
+typedef int64_t xmlrpc_int64;
45+
/* An integer of the type defined by "XML-RPC" <i8>; i.e. 64 bit */
46+
typedef int xmlrpc_bool;
47+
/* A boolean (of the type defined by XML-RPC <boolean>, but there's
48+
@@ -112,7 +113,7 @@ typedef int xmlrpc_socket;
49+
#define XMLRPC_INT32_MAX 0x7fffffff
50+
#define XMLRPC_INT32_MIN (-XMLRPC_INT32_MAX - 1)
51+
52+
-#define XMLRPC_INT64_MAX 0x7fffffffffffffffll
53+
+#define XMLRPC_INT64_MAX ((xmlrpc_int64)0x7fffffffffffffffll)
54+
#define XMLRPC_INT64_MIN (-XMLRPC_INT64_MAX - 1)
55+
56+
57+
diff --git a/lib/libutil/string_number.c b/lib/libutil/string_number.c
58+
index 1c284af..a7e78ad 100644
59+
--- a/lib/libutil/string_number.c
60+
+++ b/lib/libutil/string_number.c
61+
@@ -6,6 +6,7 @@
62+
============================================================================*/
63+
#include <stdlib.h>
64+
#include <string.h>
65+
+#include <inttypes.h>
66+
#include <errno.h>
67+
68+
#include <xmlrpc-c/base.h>
69+
diff --git a/src/cpp/param_list.cpp b/src/cpp/param_list.cpp
70+
index 1f7ae41..60f7df9 100644
71+
--- a/src/cpp/param_list.cpp
72+
+++ b/src/cpp/param_list.cpp
73+
@@ -277,7 +277,7 @@ paramList::getI8(unsigned int const paramNumber,
74+
throw(fault("Parameter that is supposed to be 64-bit integer is not",
75+
fault::CODE_TYPE));
76+
77+
- long long const longlongvalue(static_cast<long long>(
78+
+ xmlrpc_int64 const longlongvalue(static_cast<xmlrpc_int64>(
79+
value_i8(this->paramVector[paramNumber])));
80+
81+
if (longlongvalue < minimum)
82+
--
83+
2.13.1
84+
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
From 9bb040a9ae29e1b5afcb674c74f107114b316818 Mon Sep 17 00:00:00 2001
2+
From: Enrico Scholz <[email protected]>
3+
Date: Thu, 29 Jul 2010 19:25:32 +0200
4+
Subject: [PATCH 3/3] allow 30x redirections
5+
6+
---
7+
lib/curl_transport/curltransaction.c | 4 ++++
8+
1 file changed, 4 insertions(+)
9+
10+
diff --git a/lib/curl_transport/curltransaction.c b/lib/curl_transport/curltransaction.c
11+
index f0aafae..b5392a9 100644
12+
--- a/lib/curl_transport/curltransaction.c
13+
+++ b/lib/curl_transport/curltransaction.c
14+
@@ -671,6 +671,10 @@ setupCurlSession(xmlrpc_env * const envP,
15+
16+
curl_easy_setopt(curlSessionP, CURLOPT_POST, 1);
17+
curl_easy_setopt(curlSessionP, CURLOPT_URL, transP->serverUrl);
18+
19+
+ curl_easy_setopt(curlSessionP, CURLOPT_FOLLOWLOCATION, 1);
20+
+ curl_easy_setopt(curlSessionP, CURLOPT_MAXREDIRS, (long)10);
21+
+ curl_easy_setopt(curlSessionP, CURLOPT_POSTREDIR, CURL_REDIR_POST_ALL);
22+
+
23+
XMLRPC_MEMBLOCK_APPEND(char, envP, transP->postDataP, "\0", 1);
24+
if (!envP->fault_occurred) {
25+
curl_easy_setopt(curlSessionP, CURLOPT_POSTFIELDS,
26+
--
27+
2.13.1
28+
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"Signatures": {
3-
"xmlrpc-c-1.54.06.tgz": "ae6d0fb58f38f1536511360dc0081d3876c1f209d9eaa54357e2bacd690a5640"
3+
"xmlrpc-c-1.60.04.tgz": "1e98cc6f524142c2b80731778fe8c74458936118bf95ae33cfa1e9205bfd48a5"
44
}
55
}

0 commit comments

Comments
 (0)