]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-program-client: Compiler warning fixes
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Mon, 10 Oct 2016 11:42:24 +0000 (14:42 +0300)
committerTimo Sirainen <timo.sirainen@dovecot.fi>
Mon, 10 Oct 2016 11:42:45 +0000 (14:42 +0300)
src/lib-program-client/test-program-client-remote.c

index 07219f2d10bd3950af8c7522cf2d171e2f12cc96..0dc78b58e2d537ef236e80aadff49f0cb5c3a979 100644 (file)
@@ -83,7 +83,7 @@ void test_program_client_destroy(struct test_client **_client)
 }
 
 static
-int test_program_input_handle(struct test_client *client, char *line)
+int test_program_input_handle(struct test_client *client, const char *line)
 {
        size_t siz;
        ssize_t ret;
@@ -169,7 +169,7 @@ static
 void test_program_input(struct test_client *client)
 
 {
-       char *line;
+       const char *line = "";
 
        if (client->state == CLIENT_STATE_BODY) {
                if (test_program_input_handle(client, NULL)==0 && !client->in->eof) return;
@@ -232,7 +232,7 @@ static
 void test_program_teardown(void)
 {
        test_begin("test_program_teardown");
-       if (test_globals.client)
+       if (test_globals.client != NULL)
                test_program_client_destroy(&test_globals.client);
        io_remove(&test_globals.io);
        close(test_globals.listen_fd);