3 ms·
This has more far reaching consequences. You can't create pointers to strings, or you have to restrict them to only point at the head of strings. You would st
by jandrese 11y ago
This has more far reaching consequences. You can't create pointers to strings, or you have to restrict them to only point at the head of strings. You would still have overruns, but the focus would be on overwriting the length field at the start of the string instead of overwriting the null at the end, or maybe overwriting the length on the next string. This is a seismic change to just about everything string related in C, the days of people iterating over characters with a pointer would be over.
Just think about how something like strsep (strtok to you older folks) would work in a system like this.