tweaked: mmapping the file works inside main() but not when I try and pass pointer to a function (can't access memory address). going to play with moving into the function and return the pointer