Added tests to catch File perm errors in putXXent functions

   Fixed up passwd functions calling those functions, group.c still
   needs to be fixed.

   All four of those functions could be optimized, I'm sure.