#include main() { int c, where = -1, line = 0; int start; int null = 0; while ((c = getchar()) != EOF) { where++; if (c == '\n') line++; if (c && null) { fprintf(stderr, "Found null start 0x%x end 0x%x len 0x%x line %d\n", start, where, where - start, line); } if (c) {null = 0; continue;} if (null) continue; start = where; null = 1; } }