**Describe the unexpected behaviour**
On connection with server having self-signed certificate warning message and acceptance request issued twice.

**How to reproduce**
Provide server with self-signed certificate and make a secure connection.

**Expected behavior**
Only one warning message and acceptance request should be issued.

**Error message and/or stacktrace**
```
ubuntu@ip-172-31-42-195:~/ClickHouse-comb/build_debug/programs$ ./clickhouse-client -s --port 9541
ClickHouse client version 22.9.1.1.
Connecting to localhost:9541 as user default.

WARNING: Certificate verification failed
----------------------------------------
Issuer Name:  /CN=another
Subject Name: /CN=another

The certificate yielded the error: self signed certificate

The error occurred in the certificate chain at position 0
Accept the certificate (y,n)? y
Connected to ClickHouse server version 22.9.1 revision 54460.

Warnings:
 * Server was built in debug mode. It will work slowly.

ip-172-31-42-195.us-east-2.compute.internal :)
WARNING: Certificate verification failed
----------------------------------------
Issuer Name:  /CN=another
Subject Name: /CN=another

The certificate yielded the error: self signed certificate

The error occurred in the certificate chain at position 0
Accept the certificate (y,n)?
```
if (ast_2)
            {
                const auto text_2 = ast_2->formatForErrorMessage();
                const auto * tmp_pos = text_2.c_str();
                const auto ast_3 = parseQuery(tmp_pos, tmp_pos + text_2.size(),
                    false );
                const auto text_3 = ast_3->formatForErrorMessage();
                if (text_3 != text_2)
                {
                    fmt::print(stderr, "Found error: The query formatting is broken.\n");
                    printChangedSettings();
                    fmt::print(stderr,
                        "Got the following (different) text after formatting the fuzzed query and parsing it back:\n'{}'\n, expected:\n'{}'\n",
                        text_3, text_2);
                    fmt::print(stderr, "In more detail:\n");
                    fmt::print(stderr, "AST-1 (generated by fuzzer):\n'{}'\n", parsed_query->dumpTree());
                    fmt::print(stderr, "Text-1 (AST-1 formatted):\n'{}'\n", query_to_execute);
                    fmt::print(stderr, "AST-2 (Text-1 parsed):\n'{}'\n", ast_2->dumpTree());
                    fmt::print(stderr, "Text-2 (AST-2 formatted):\n'{}'\n", text_2);
                    fmt::print(stderr, "AST-3 (Text-2 parsed):\n'{}'\n", ast_3->dumpTree());
                    fmt::print(stderr, "Text-3 (AST-3 formatted):\n'{}'\n", text_3);
                    fmt::print(stderr, "Text-3 must be equal to Text-2, but it is not.\n");
                    _exit(1);
                }
            }
        }
        
        
        if (have_error)
        {