aboutsummaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorGravatar Craig Tiller <craig.tiller@gmail.com>2015-12-14 20:49:37 -0800
committerGravatar Craig Tiller <craig.tiller@gmail.com>2015-12-14 20:49:37 -0800
commitaf745d824ebee17ef17e501eb2d169a6054c9dfc (patch)
tree5b576366de9fe335fdf190c89e27cb48926250c8 /test
parentc482945ba7407de52ac94a7e85599b1398dcb43d (diff)
Fix build
Diffstat (limited to 'test')
-rw-r--r--test/core/httpcli/httpcli_test.c4
-rw-r--r--test/core/httpcli/httpscli_test.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/test/core/httpcli/httpcli_test.c b/test/core/httpcli/httpcli_test.c
index fc51cb0101..612388c61d 100644
--- a/test/core/httpcli/httpcli_test.c
+++ b/test/core/httpcli/httpcli_test.c
@@ -151,11 +151,11 @@ int main(int argc, char **argv) {
/* figure out where we are */
char *root;
if (lslash) {
- root = gpr_malloc(lslash - me + 1);
+ root = gpr_malloc((size_t)(lslash - me + 1));
memcpy(root, me, (size_t)(lslash - me));
root[lslash - me] = 0;
} else {
- root = strdup(".");
+ root = gpr_strdup(".");
}
gpr_asprintf(&args[0], "%s/../../test/core/httpcli/test_server.py", root);
gpr_free(root);
diff --git a/test/core/httpcli/httpscli_test.c b/test/core/httpcli/httpscli_test.c
index 4cfa9e59b0..ba5660bd18 100644
--- a/test/core/httpcli/httpscli_test.c
+++ b/test/core/httpcli/httpscli_test.c
@@ -153,11 +153,11 @@ int main(int argc, char **argv) {
/* figure out where we are */
char *root;
if (lslash) {
- root = gpr_malloc(lslash - me + 1);
+ root = gpr_malloc((size_t)(lslash - me + 1));
memcpy(root, me, (size_t)(lslash - me));
root[lslash - me] = 0;
} else {
- strcpy(root, ".");
+ root = gpr_strdup(".");
}
gpr_asprintf(&args[0], "%s/../../test/core/httpcli/test_server.py", root);
gpr_free(root);