fixed checking of memory allocation result by private file name string