summaryrefslogtreecommitdiff
path: root/src/transport-http.c
Commit message (Collapse)AuthorAgeFilesLines
* Move the transports to their own directoryCarlos Martín Nieto2011-10-121-790/+0
|
* net: plug a few memory leaksCarlos Martín Nieto2011-10-121-2/+14
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: download pack when fetchingCarlos Martín Nieto2011-10-121-12/+123
| | | | | | | Unfortunately, we can't use the function in fetch.c due to chunked encoding and keep-alive connections. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: simple negotiationCarlos Martín Nieto2011-10-121-27/+57
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: parse the response from the serverCarlos Martín Nieto2011-10-121-9/+107
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: add a set of common refsCarlos Martín Nieto2011-10-121-14/+40
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: move stuff out of negotiate_fetchCarlos Martín Nieto2011-10-121-44/+62
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* transport: don't have an extra send-wants stepCarlos Martín Nieto2011-10-121-18/+13
| | | | | | | It's a bit awkward to run it as an extra step, and HTTP may need to send the wants list several times. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: Start negotiate_fetchCarlos Martín Nieto2011-10-121-0/+92
|
* http: add more modularity to the codeCarlos Martín Nieto2011-10-121-46/+47
| | | | | | | | Not every request needs a new connection if we're using a keep-alive connection. Store the HTTP parser, host and port in the transport in order to have it available in later calls. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* Squelch a couple of warningsCarlos Martín Nieto2011-10-011-1/+1
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http-transport: Properly cleanup the WSA contextVicent Marti2011-10-011-13/+13
|
* http-transport: Update copyrightVicent Marti2011-10-011-21/+3
|
* netops: abstract away socket closingCarlos Martín Nieto2011-10-011-1/+1
| | | | | | | Winsock wants us to use closesocket() instead of close(), so introduce the gitno_close function, which does the right thing. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* Initialise the winsock DLLCarlos Martín Nieto2011-10-011-1/+20
| | | | | | | | Windows wants us to initialise the networking DLL before we're allowed to send data through a socket. Call WSASetup and WSACleanup if GIT_WIN32 is defined. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* Fix dev branch under MSVCCarlos Martín Nieto2011-09-271-7/+10
| | | | | | | | | | | | | In libgit2: Move an enum out of an int bitfield in the HTTP transport. In the parser: Use int bitfields and change some variable sizes to better fit thir use. Variables that count the size of the data chunk can only ever be as large as off_t. Warning 4127 can be ignored, as nobody takes it seriously anyway. From Emeric: change some variable declarations to keep MSVC happy. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: get rid of the global stateCarlos Martín Nieto2011-09-211-20/+23
| | | | | | | Move the header parsing state into the transport, making use of the existing bitfield. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: also store Content-Type if it's the last fieldCarlos Martín Nieto2011-09-121-0/+6
| | | | | | | When Content-Type is the last field, we only know when we can store it when we reach on_headers_complete. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* http: store which service to expectCarlos Martín Nieto2011-09-121-8/+19
| | | | | | | | Depending on what we want to do, we expect the Content-Type field to have different contents. Store which service to expect instead of hard-coding the string. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* Implement ls-remote over smart HTTPCarlos Martín Nieto2011-09-121-0/+325
| | | | Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
* Add HTTP transport skeletonCarlos Martín Nieto2011-09-041-0/+58
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>