There's a precedence problem with this code, too which might cause problems.
You either need to use 'or' rather than '||' or to wrap the arguments to mkdir in parentheses. What you're saying here is effectively:
mkdir $dir;
0755 || BL::GenLib::MiscErr("Could not make $dir");