Allocate proper space for array.

Do not allocate MAXPATHLEN * len for an array of char * pointers.