Skip to content

Commit 235b96d

Browse files
committed
fix
1 parent c8dcded commit 235b96d

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

cores/esp8266/core_esp8266_eboot_command.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ extern "C" {
2929

3030
static uint32_t eboot_command_calculate_crc32(const struct eboot_command* cmd)
3131
{
32-
return crc32((const uint8_t*) cmd, offsetof(struct eboot_command, crc32));
32+
return crc32((const uint8_t*) cmd, offsetof(struct eboot_command, crc32), 0xffffffff);
3333
}
3434

3535
int eboot_command_read(struct eboot_command* cmd)

cores/esp8266/core_esp8266_features.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,10 @@
3333
#define WIFI_HAS_EVENT_CALLBACK
3434
#define WIFI_IS_OFF_AT_BOOT
3535

36-
#include <stdlib.h> // malloc()
36+
#include <stdbool.h> // bool
3737
#include <stddef.h> // size_t
3838
#include <stdint.h>
39+
#include <stdlib.h> // malloc()
3940

4041
#ifndef __STRINGIFY
4142
#define __STRINGIFY(a) #a

cores/esp8266/coredecls.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,15 @@ void esp_delay(unsigned long ms);
2020
void esp_schedule();
2121
void esp_yield();
2222
void tune_timeshift64 (uint64_t now_us);
23+
bool sntp_set_timezone_in_seconds(int32_t timezone);
24+
2325
void disable_extra4k_at_link_time (void) __attribute__((noinline));
2426
void enable_wifi_enterprise_patch(void) __attribute__((noinline));
25-
bool sntp_set_timezone_in_seconds(int32_t timezone);
2627
void __disableWiFiAtBootTime (void) __attribute__((noinline));
2728
void __real_system_restart_local() __attribute__((noreturn));
2829

29-
uint32_t sqrt32 (uint32_t n);
30-
uint32_t crc32 (const void* data, size_t length, uint32_t crc = 0xffffffff);
30+
uint32_t sqrt32(uint32_t n);
31+
uint32_t crc32(const void* data, size_t length, uint32_t crc);
3132

3233
#ifdef __cplusplus
3334
}

cores/esp8266/crc32.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
#include "pgmspace.h"
2424

2525
// moved from core_esp8266_eboot_command.cpp
26-
uint32_t crc32 (const void* data, size_t length, uint32_t crc /*= 0xffffffff*/)
26+
uint32_t crc32 (const void* data, size_t length, uint32_t crc)
2727
{
2828
const uint8_t* ldata = (const uint8_t*)data;
2929
while (length--)

0 commit comments

Comments
 (0)