johnmehr / gitup

A minimalist, dependency-free FreeBSD program to clone/pull Git repositories.
BSD 2-Clause "Simplified" License
51 stars 9 forks source link

Location of setsocketopt #60

Closed michael-o closed 3 years ago

michael-o commented 3 years ago

I am by far not an expect, but I am confused why socket options are set here: https://github.com/johnmehr/gitup/blob/2547cfcaf9ddf20b4ebb9b6aac6b7b1c0fc7d56d/gitup.c#L853-L871 in setup_ssl() instead of in connect_server(). TLS is set up when the connection has already been established.

johnmehr commented 3 years ago

This was a bad copy/paste on my part. How does it look now?

michael-o commented 3 years ago

LGTM.