lchar() needs to return the character written. (This happens by magic on 386,

but no on PPC.) See #72.
This commit is contained in:
David Given 2018-03-11 11:00:35 +01:00
parent 03386b96f9
commit d5a9f1541a

View file

@ -14,10 +14,11 @@ static intptr_t i_char(intptr_t s, intptr_t n)
return p[n]; return p[n];
} }
static void i_lchar(intptr_t s, intptr_t n, intptr_t c) static intptr_t i_lchar(intptr_t s, intptr_t n, intptr_t c)
{ {
char* p = (char*)(s<<SHIFT); char* p = (char*)(s<<SHIFT);
p[n] = c; p[n] = c;
return c;
} }
static intptr_t i_getchar(void) static intptr_t i_getchar(void)