Hi Sergey, We used curl to fetch data(response) from external server over http protocol and use mongoose mg_send_data or mg_send_header to send the headers back to client. The question is how to make sure of sending http chunked transfers to client if the response from the forwarded server is chunked.
Thanks, KK On Friday, November 7, 2014 5:29:36 AM UTC-5, Sergey Lyubka wrote: > > Hi Swati, > > I didn't fully understand the issue. > Could you elaborate more, step-by-step, please? > > On Wed, Nov 5, 2014 at 8:56 AM, swati joshi <[email protected] > <javascript:>> wrote: > >> Hi there, >> >> I am using mongoose as a local webserver. >> This server makes use of cURL to fetch headers / data from external >> websites / webservers. >> >> Now , to send data , I use mg_send_data(conn, data, sizeof(data)); - >> which works perfectly fine. >> >> My issue is, I get header data also in chunk. like this >> "HTTP/1.1 401 Unauthorized Content-Type: application/json Date: Wed, 05 >> Nov 2014 08:51:40 GMT Server: WildFly/8 X-Powered-By: Undertow/1 >> transfer-encoding: chunked Connection: keep-alive" >> >> How do I send it to my client ? >> mg_send_headers( ) - would not be appropriate coz header info i have is >> in chunk and i am not sure how to seperate it as to use this API. >> >> Kindly help on how can this chunked recieved header be sent to client. >> >> Thanks, >> Swati >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "mongoose-users" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> To post to this group, send email to [email protected] >> <javascript:>. >> Visit this group at http://groups.google.com/group/mongoose-users. >> For more options, visit https://groups.google.com/d/optout. >> > > -- You received this message because you are subscribed to the Google Groups "mongoose-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/mongoose-users. For more options, visit https://groups.google.com/d/optout.
