ITADN

Compiler warning when using 64 bit patch

#205Openratioguy 创建于 2026-04-22
R
ratioguycommented
``` -> Entering step: "Build "nextvi" using "cc"" -> cc vi.c -o vi -pedantic -Wall -Wextra -Wno-implicit-fallthrough -Wno-missing-field-initializers -Wno-unused-parameter -Wno-unused-result -Wfatal-errors -std=c99 -O2 -D_POSIX_C_SOURCE=200809L In function ‘emalloc’, inlined from ‘ren_position’ at ren.c:124:15: vi.c:51:19: warning: argument 1 value ‘18446744073709551608’ exceeds maximum object size 9223372036854775807 [-Walloc-size-larger-than=] 51 | if (!(p = malloc(size))) { | ^~~~~~~~~~~~ In file included from vi.c:5: /usr/include/stdlib.h: In function ‘ren_position’: /usr/include/stdlib.h:672:14: note: in a call to allocation function ‘malloc’ declared here 672 | extern void *malloc (size_t __size) __THROW __attribute_malloc__ | ^~~~~~ ``` Also just wanted to say great work I've been trying to find a good VI editor and I think this one is great!
1 条评论