Use getFileContents() instead of incorrect file system call to fetch file contents.

Change-Id: I2b9be4165ae85c52ff9a9b68b9d71ec011a6c5b4
Merge "Use getFileContents() instead of incorrect file system call to fetch file contents."