1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-18 17:07:24 +00:00

version.h defines "UNSIGNED" as the type for pointer-sized integer. Using "unsigned" may produce the wrong answer on a 64-bit system.

modified:   ../src/findkey.c
This commit is contained in:
Nick Briggs 2020-12-09 16:14:53 -08:00
parent a6db884947
commit af50a35911

View File

@ -11,6 +11,7 @@ static char *id = "$Id: findkey.c,v 1.3 1999/05/31 23:35:28 sybalsky Exp $ Copyr
#include "version.h"
#include <stdint.h>
#include "lispemul.h"
#include "lispmap.h"
#include "emlglob.h"
@ -52,7 +53,7 @@ LispPTR N_OP_findkey(register LispPTR tos, register int byte) {
arg_nth = byte + 1;
for (ptr = (LispPTR *)(IVar + ((byte * 2) - 2)); (unsigned)find_end >= (unsigned)ptr;
for (ptr = (LispPTR *)(IVar + ((byte * 2) - 2)); (uintptr_t)find_end >= (uintptr_t)ptr;
ptr += 2, arg_nth += 2) {
if (*ptr == tos) { /* KEY founded */
return (S_POSITIVE | arg_nth);