char* filename[MAX_STR_LEN];
That declares an array of pointers, and doesn't initialise them to point to anything. Dereferencing them gives undefined behaviour; if you're lucky, a segmentation fault.
You probably meant to declare an array of characters to contain the string:
char filename[MAX_STR_LEN];
strcpy(filename, argv[1]);
Now you just need to make sure the array is large enough; or stop mucking around with low-level C artifacts and use std::string
instead.