Fixed some permissions and filename stuff.