是否有可以标记以下错误的动态检查实用程序?瓦尔格林不能。可以净化或保险++吗?这是在 Linux Ubuntu 最新版本上。
struct A {
char buff1[8];
int jj;
char buff2[8];
int ii;
char buff3[8];
} a;
main(int argc, char *args[])
{
// Set intermediate fields to known flag value
a.ii = a.jj = 0xdeadbeef;
// Write 8 char string into 8 byte buffer - null will overflow into neighboring int field. ERROR
sprintf(a.buff2, "ABCDEFGH");
}