[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] Dealloc in fs_close_custom()?
From: |
Simon Goldschmidt |
Subject: |
Re: [lwip-users] Dealloc in fs_close_custom()? |
Date: |
Tue, 27 Feb 2018 06:39:15 +0100 |
Giuseppe Modugno wrote:
> #ifndef HTTP_IS_DATA_VOLATILE
> #if LWIP_HTTPD_SSI
> /* Copy for SSI files, no copy for non-SSI files */
> #define HTTP_IS_DATA_VOLATILE(hs) ((hs)->ssi ? TCP_WRITE_FLAG_COPY : 0)
> #else /* LWIP_HTTPD_SSI */
> /** Default: don't copy if the data is sent from file-system directly */
> #define HTTP_IS_DATA_VOLATILE(hs) (((hs->file != NULL) && (hs->handle !=
> NULL) && (hs->file == \
> (const char*)hs->handle->data +
> hs->handle->len - hs->left)) \
> ? 0 : TCP_WRITE_FLAG_COPY)
> #endif /* LWIP_HTTPD_SSI */
> #endif
You're looking at an "old" version of the file. git master has this since last
may:
#ifndef HTTP_IS_DATA_VOLATILE
/** tcp_write does not have to copy data when sent from rom-file-system
directly */
#define HTTP_IS_DATA_VOLATILE(hs) (HTTP_IS_DYNAMIC_FILE(hs) ?
TCP_WRITE_FLAG_COPY : 0)
#endif
> First of all, are the results of HTTP_IS_DATA_VOLATILE() reversed when
> LWIP_HTTPD_SSI is reset?
Yes, the name seems bad.
Simon