Okay! I tried it and matsp WAS WRONG!
Code:
#include <stdio.h>
struct thest {
int one;
int two;
} ray[];
int array[10];
int main () {
int i;
for (i=0; i<10; i++) {
array[i] = i*3;
}
for (i=0; i<=4; i++) {
ray[i].one = i;
ray[i].two = i*2;
}
for (i=0; i<=4; i++) printf("ray[%d]: %d\t%d\n", i,ray[i].one,ray[i].two);
for (i=0; i<10; i++) {
if (array[i] != i*3) printf("array[%d] isn't %d, it's %d...\n",i,i*3,array[i]);
else puts("No problem");
}
}
Sorry the "code" tags don't work here (?!?). But the output is:
Code:
ray[0]: 0 0
ray[1]: 1 2
ray[2]: 2 4
ray[3]: 3 6
ray[4]: 4 8
No problem
No problem
No problem
No problem
No problem
No problem
No problem
No problem
No problem
No problem
But I clearly haven't hit a 4k boundary yet. Also,
#define _GNU_SOURCE
didn't make any difference with strcasestr.
Of course, now all subsequent unexplained segfaults will leave me paranoid...