I don't think its a font path problem. The font paths can be specified at the command line with -fp /<path1>/,/<path2/,... and it loads all fonts fine, including the "fixed" ones from /usr/share/fonts/misc/ folder specified on the command line and the ALTERNATE paths specified in the code.
If I change the font with -fn to "9x15" to be the default font, it still fails to open the default font "9x15". I know for a fact that 9x15 font exists in the custom paths I have specified using -fp.
So, its not a font path issue. Its what happens when it wants to set the default font and calls those 2 functions. Most likely, the second function is the one which is failing because the fist function has failure cases only for allocation failures.
-devsk