[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Re: [lwip-users] Problem with multi file sending http server

From: Mariusz Dz
Subject: Re: Re: [lwip-users] Problem with multi file sending http server
Date: Thu, 25 Nov 2010 22:45:17 +0100

I hope i understand order of calls, now i have got order like this:

//some operation on data
//close file etc.

hs->file = pointer_on_data;
hs->left = data_length
tcp_recved(pcb, p->tot_len);
send_data(pcb, hs);
tcp_sent(pcb, http_sent);

But that dont change in appearing problem loosing some data, that can be one
sign and file like css or js make big troubles, maybe there is a solution in
somehowe slow transmition that i will send next file when there will be know
that last file had been send.

The http_sent is:

static err_t
http_sent(void *arg, struct tcp_pcb *pcb, u16_t len)
  struct http_state *hs;

  hs = arg;

  if (hs->left > 0)
    send_data(pcb, hs);
    close_conn(pcb, hs);

  return ERR_OK;

Chcesz więcej zarabiać? Zmień pracę na lepszą!

reply via email to

[Prev in Thread] Current Thread [Next in Thread]