unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH] Fix compilation warnings in test/smtp-dummy.c.
@ 2011-06-16 10:32 Dmitry Kurochkin
  2011-06-21 21:59 ` Carl Worth
  0 siblings, 1 reply; 2+ messages in thread
From: Dmitry Kurochkin @ 2011-06-16 10:32 UTC (permalink / raw)
  To: notmuch

* Remove unused variables in main(): buf, bytes and greeting.
* Replace return with no value in main() with exit(3).
---
 test/smtp-dummy.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/test/smtp-dummy.c b/test/smtp-dummy.c
index e58d0ad..133d6c4 100644
--- a/test/smtp-dummy.c
+++ b/test/smtp-dummy.c
@@ -99,9 +99,6 @@ process_command (FILE *peer, FILE *output, const char *command)
 static void
 do_smtp_to_file (FILE *peer, FILE *output)
 {
-	char buf[4096];
-	ssize_t bytes;
-	char greeting[] = "220 localhost smtp-dummy\r\n";
 	char *line = NULL;
 	size_t line_size;
 	ssize_t line_len;
@@ -193,7 +190,7 @@ main (int argc, char *argv[])
 	if (peer_file == NULL) {
 		fprintf (stderr, "Error: fdopen() failed: %s\n",
 			 strerror (errno));
-		return;
+		exit (1);
 	}
 
 	do_smtp_to_file (peer_file, output);
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-06-21 21:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-16 10:32 [PATCH] Fix compilation warnings in test/smtp-dummy.c Dmitry Kurochkin
2011-06-21 21:59 ` Carl Worth

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).