summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2014-02-26 19:03:10 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2014-02-26 19:03:10 +0200
commit25df2275c794c9f223715473494ab3b10a420d40 (patch)
tree9da8168523d9f16910e36ece26de5a30f71aa11e /examples
parent144bf5da108539d9893a90d1024539500d85a390 (diff)
downloadmailutils-25df2275c794c9f223715473494ab3b10a420d40.tar.gz
mailutils-25df2275c794c9f223715473494ab3b10a420d40.tar.bz2
Clean up unused variables.
Diffstat (limited to 'examples')
-rw-r--r--examples/base64.c6
-rw-r--r--examples/http.c4
2 files changed, 4 insertions, 6 deletions
diff --git a/examples/base64.c b/examples/base64.c
index 0d9b66e95..8f9e05160 100644
--- a/examples/base64.c
+++ b/examples/base64.c
@@ -56,16 +56,14 @@ c_copy (mu_stream_t out, mu_stream_t in)
while (mu_stream_read (in, &c, 1, &size) == 0 && size > 0)
{
- int rc;
-
if (printable && !ISPRINT (c))
{
char outbuf[24];
sprintf (outbuf, "\\%03o", (unsigned char) c);
- rc = mu_stream_write (out, outbuf, strlen (outbuf), NULL);
+ MU_ASSERT (mu_stream_write (out, outbuf, strlen (outbuf), NULL));
}
else
- rc = mu_stream_write (out, &c, 1, NULL);
+ MU_ASSERT (mu_stream_write (out, &c, 1, NULL));
}
}
else
diff --git a/examples/http.c b/examples/http.c
index 60d5a69e8..b54ab363a 100644
--- a/examples/http.c
+++ b/examples/http.c
@@ -72,7 +72,7 @@ main (int argc, char **argv)
{
int ret;
mu_stream_t stream;
- size_t nb, size;
+ size_t nb;
size_t attempt;
char *url = "www.gnu.org";
@@ -110,7 +110,7 @@ main (int argc, char **argv)
exit (EXIT_FAILURE);
}
- for (attempt = 0, size = strlen (wbuf);; )
+ for (attempt = 0;; )
{
ret = mu_stream_write (stream, wbuf, strlen (wbuf), NULL);
if (ret == 0)

Return to:

Send suggestions and report system problems to the System administrator.