Skip to content

Commit 64ad838

Browse files
committed
esp8266/esp_mphal: Implement libc's errno.
Using __errno() function, and redirect it to use mp_stream_errno from stream module. This is pre-requisite for integrating with 3rd-party libs, like BerkeleyDB.
1 parent 617bda2 commit 64ad838

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

esp8266/esp_mphal.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,3 +259,8 @@ int ets_esf_free_bufs(int idx) {
259259
}
260260
return cnt;
261261
}
262+
263+
extern int mp_stream_errno;
264+
int *__errno() {
265+
return &mp_stream_errno;
266+
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy