From: Rusty Russell Date: Tue, 22 Mar 2011 02:13:03 +0000 (+1030) Subject: antithread: fix -Wwrite-strings warning in test, and trailing whitespace. X-Git-Url: https://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=5b0bdc23fbc8549f8d2e3034cd0c3e018dd994ad;hp=e5d378237fd2c9dd0c710bed9d8f9e1538de6d02;ds=inline antithread: fix -Wwrite-strings warning in test, and trailing whitespace. --- diff --git a/ccan/antithread/antithread.c b/ccan/antithread/antithread.c index da607c1e..e3f3bac9 100644 --- a/ccan/antithread/antithread.c +++ b/ccan/antithread/antithread.c @@ -420,7 +420,7 @@ struct at_pool *at_get_pool(int *argc, char *argv[], void **arg) p = atp->p = talloc(atp, struct at_pool_contents); - if (sscanf(argv[1], "AT:%p/%lu/%i/%i/%i/%p", + if (sscanf(argv[1], "AT:%p/%lu/%i/%i/%i/%p", &p->pool, &p->poolsize, &p->fd, &p->parent_rfd, &p->parent_wfd, arg) != 6) { errno = EINVAL; diff --git a/ccan/antithread/test/run-spawn.c b/ccan/antithread/test/run-spawn.c index b8aa81e5..f1dcd2f8 100644 --- a/ccan/antithread/test/run-spawn.c +++ b/ccan/antithread/test/run-spawn.c @@ -8,7 +8,7 @@ int main(int argc, char *argv[]) struct athread *at; int err, *pid; void *arg; - char *bad_args[] = { "/", NULL }; + char *bad_args[] = { (char *)"/", NULL }; atp = at_get_pool(&argc, argv, &arg); if (atp) {