Commit 1e10378a authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Fix printf formats for 32/64 issues

parent e633a7f8
......@@ -871,7 +871,8 @@ cmd_http_txreq(CMD_ARGS)
if (*av != NULL)
vtc_log(hp->vl, 0, "Unknown http txreq spec: %s\n", *av);
if (body != NULL)
vsb_printf(hp->vsb, "Content-Length: %lu%s", strlen(body), nl);
vsb_printf(hp->vsb, "Content-Length: %ju%s",
(uintmax_t)strlen(body), nl);
vsb_cat(hp->vsb, nl);
if (body != NULL) {
vsb_cat(hp->vsb, body);
......@@ -916,7 +917,8 @@ cmd_http_chunked(CMD_ARGS)
AN(av[1]);
AZ(av[2]);
vsb_clear(hp->vsb);
vsb_printf(hp->vsb, "%lx%s%s%s", strlen(av[1]), nl, av[1], nl);
vsb_printf(hp->vsb, "%jx%s%s%s",
(uintmax_t)strlen(av[1]), nl, av[1], nl);
http_write(hp, 4, "chunked");
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment