You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by as...@apache.org on 2016/12/14 20:16:53 UTC
qpid-proton git commit: PROTON-1375: Don't use default promoted
parameter to va_start
Repository: qpid-proton
Updated Branches:
refs/heads/master ce8db5a80 -> 79d06f070
PROTON-1375: Don't use default promoted parameter to va_start
Project: http://git-wip-us.apache.org/repos/asf/qpid-proton/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-proton/commit/79d06f07
Tree: http://git-wip-us.apache.org/repos/asf/qpid-proton/tree/79d06f07
Diff: http://git-wip-us.apache.org/repos/asf/qpid-proton/diff/79d06f07
Branch: refs/heads/master
Commit: 79d06f0705a973a00fc66283462fa12ad729a708
Parents: ce8db5a
Author: Andrew Stitcher <as...@apache.org>
Authored: Wed Dec 14 15:12:23 2016 -0500
Committer: Andrew Stitcher <as...@apache.org>
Committed: Wed Dec 14 15:12:23 2016 -0500
----------------------------------------------------------------------
proton-c/src/tests/object.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/79d06f07/proton-c/src/tests/object.c
----------------------------------------------------------------------
diff --git a/proton-c/src/tests/object.c b/proton-c/src/tests/object.c
index 4008fc6..8a1d00e 100644
--- a/proton-c/src/tests/object.c
+++ b/proton-c/src/tests/object.c
@@ -50,14 +50,14 @@ static pn_list_t *build_list(size_t capacity, ...)
return result;
}
-static pn_map_t *build_map(size_t capacity, float load_factor, ...)
+static pn_map_t *build_map(float load_factor, size_t capacity, ...)
{
pn_map_t *result = pn_map(PN_OBJECT, PN_OBJECT, capacity, load_factor);
va_list ap;
void *prev = NULL;
- va_start(ap, load_factor);
+ va_start(ap, capacity);
int count = 0;
while (true) {
void *arg = va_arg(ap, void *);
@@ -397,7 +397,7 @@ static void test_build_list(void)
static void test_build_map(void)
{
- pn_map_t *m = build_map(0, 0.75,
+ pn_map_t *m = build_map(0.75, 0,
pn_string("key"),
pn_string("value"),
pn_string("key2"),
@@ -421,7 +421,7 @@ static void test_build_map(void)
static void test_build_map_odd(void)
{
- pn_map_t *m = build_map(0, 0.75,
+ pn_map_t *m = build_map(0.75, 0,
pn_string("key"),
pn_string("value"),
pn_string("key2"),
@@ -767,24 +767,24 @@ void test_map_inspect(void)
// note that when there is more than one entry in a map, the order
// of the entries is dependent on the hashes involved, it will be
// deterministic though
- pn_map_t *m = build_map(0, 0.75, END);
+ pn_map_t *m = build_map(0.75, 0, END);
test_inspect(m, "{}");
pn_free(m);
- m = build_map(0, 0.75,
+ m = build_map(0.75, 0,
pn_string("key"), pn_string("value"),
END);
test_inspect(m, "{\"key\": \"value\"}");
pn_free(m);
- m = build_map(0, 0.75,
+ m = build_map(0.75, 0,
pn_string("k1"), pn_string("v1"),
pn_string("k2"), pn_string("v2"),
END);
test_inspect(m, "{\"k1\": \"v1\", \"k2\": \"v2\"}");
pn_free(m);
- m = build_map(0, 0.75,
+ m = build_map(0.75, 0,
pn_string("k1"), pn_string("v1"),
pn_string("k2"), pn_string("v2"),
pn_string("k3"), pn_string("v3"),
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org