The problem is not NULL
vs. 0
, they are the same and mean null-pointer which is a different concept than arithmetic 0 or binary 0. Your problem is most likely with the definition of your array.
String case (pointer to char):
char *s;
s = malloc(10 * sizeof(char));
s[0] = 'H'; /* set char */
s[1] = NULL; /* not ok */
s[2] = '\0'; /* binary 0, end of string marker */
Pointer of pointer to char:
char **x;
x = malloc(10 * sizeof(char *));
x[0] = "Hello"; /* let it point to string */
x[1] = NULL; /* let it point to nowhere */
x[2] = 0; /* same thing as above */
x[3] = '\0'; /* bad, expects pointer to char not char */