Fixing up hardcoded ar
general cleanup of uninitalized and unused variables