| 159 | } |
| 160 | #ifdef HAVE_TLS |
| 161 | else if (status == HTTP_STATUS_UPGRADE_REQUIRED) |
| 162 | { |
| 163 | /* Flush any error message... */ |
| 164 | httpFlush(http); |
| 165 | |
| 166 | /* Reconnect... */ |
| 167 | if (httpReconnect2(http, 30000, NULL)) |
| 168 | { |
| 169 | status = HTTP_STATUS_ERROR; |
| 170 | break; |
| 171 | } |
| 172 | |
| 173 | /* Upgrade with encryption... */ |
| 174 | httpEncryption(http, HTTP_ENCRYPTION_REQUIRED); |
| 175 | |
| 176 | /* Try again, this time with encryption enabled... */ |
| 177 | continue; |
| 178 | } |
| 179 | #endif /* HAVE_TLS */ |
| 180 | } |
| 181 | while (status == HTTP_STATUS_UNAUTHORIZED || status == HTTP_STATUS_UPGRADE_REQUIRED); |
nothing calls this directly
no test coverage detected