← Back to context Comment by gkfasdfasdf 6 days ago Does Fil-C catch uninitialized memory reads? 1 comment gkfasdfasdf Reply jitl 6 days ago malloc'd memory is zeroed in fil-c:> *zgc_alloc*> Allocate count bytes of zero-initialized memory. May allocate slightly more than count, based on the runtime's minalign (which is currently 16).> This is a GC allocation, so freeing it is optional. Also, if you free it and then use it, your program is guaranteed to panic.> libc's malloc just forwards to this. There is no difference between calling malloc and zgc_alloc.from https://fil-c.org/stdfil
jitl 6 days ago malloc'd memory is zeroed in fil-c:> *zgc_alloc*> Allocate count bytes of zero-initialized memory. May allocate slightly more than count, based on the runtime's minalign (which is currently 16).> This is a GC allocation, so freeing it is optional. Also, if you free it and then use it, your program is guaranteed to panic.> libc's malloc just forwards to this. There is no difference between calling malloc and zgc_alloc.from https://fil-c.org/stdfil
malloc'd memory is zeroed in fil-c:
> *zgc_alloc*
> Allocate count bytes of zero-initialized memory. May allocate slightly more than count, based on the runtime's minalign (which is currently 16).
> This is a GC allocation, so freeing it is optional. Also, if you free it and then use it, your program is guaranteed to panic.
> libc's malloc just forwards to this. There is no difference between calling malloc and zgc_alloc.
from https://fil-c.org/stdfil