I always thought that the size of a dynamic array had to be passed around, and that it couldn't be determined by looping through the array.

In this project I'm working on, there's bit of code:
Code:
extern char *
create_spec(DescList *input_lists, char *function)
{
    int list_count = 0;
    int l, i;
    char *str;
    while(input_lists && input_lists[list_count] != NULL)
    {
         list_count++;
    }
     ....
    ....
}
How does this NOT segfault? I thought if you went passed the bounds of an array (dynamic or static), it segfaults?