Skip to content

Commit

Permalink
Fixed a lot of gcc warnings.
Browse files Browse the repository at this point in the history
  • Loading branch information
CelliesProjects committed Feb 13, 2020
1 parent 4b35b06 commit 6c5abc2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions webservertask.ino
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@

static const char * HEADER_MODIFIED_SINCE = "If-Modified-Since";

static inline __attribute__((always_inline)) bool htmlUnmodified( const AsyncWebServerRequest * request, const char * date ) {
return request->hasHeader( HEADER_MODIFIED_SINCE ) && request->header( HEADER_MODIFIED_SINCE ).equals( date );
}

void webServerTask ( void * pvParameters ) {
static const char * WWW_USERNAME = "admin";
static const char * WWW_DEFAULT_PASSWD = "esp32";
Expand Down Expand Up @@ -703,7 +707,3 @@ bool setupMDNS( const char *hostname ) {
preferences.putString( "hostname", hostname );
return true;
}

static inline __attribute__((always_inline)) bool htmlUnmodified( const AsyncWebServerRequest * request, const char * date ) {
return request->hasHeader( HEADER_MODIFIED_SINCE ) && request->header( HEADER_MODIFIED_SINCE ).equals( date );
}

0 comments on commit 6c5abc2

Please sign in to comment.