mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-28 15:28:30 +00:00
Mint APE Loader v1.5
This change ports APE Loader to Linux AARCH64, so that Raspberry Pi users can run programs like redbean, without the executable needing to modify itself. Progress has also slipped into this change on the issue of making progress better conforming to user expectations and industry standards regarding which symbols we're allowed to declare
This commit is contained in:
parent
6843150e0c
commit
7e0a09feec
510 changed files with 1783 additions and 1483 deletions
|
@ -21,7 +21,7 @@
|
|||
#include "libc/intrin/asan.internal.h"
|
||||
#include "libc/str/str.h"
|
||||
|
||||
static noasan size_t strnlen_s_x64(const char *s, size_t n, size_t i) {
|
||||
static dontasan size_t strnlen_s_x64(const char *s, size_t n, size_t i) {
|
||||
uint64_t w;
|
||||
for (; i + 8 < n; i += 8) {
|
||||
w = *(uint64_t *)(s + i);
|
||||
|
@ -45,7 +45,7 @@ static noasan size_t strnlen_s_x64(const char *s, size_t n, size_t i) {
|
|||
* @return byte length
|
||||
* @asyncsignalsafe
|
||||
*/
|
||||
noasan size_t strnlen_s(const char *s, size_t n) {
|
||||
dontasan size_t strnlen_s(const char *s, size_t n) {
|
||||
size_t i;
|
||||
if (!s) return 0;
|
||||
if (IsAsan()) __asan_verify(s, n);
|
||||
|
@ -56,6 +56,6 @@ noasan size_t strnlen_s(const char *s, size_t n) {
|
|||
for (;; ++i) {
|
||||
if (i == n || !s[i]) break;
|
||||
}
|
||||
_unassert(i == n || (i < n && !s[i]));
|
||||
unassert(i == n || (i < n && !s[i]));
|
||||
return i;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue