AI 147028: Fix up aapt so it runs cleanly under the valgrind leak checker.

Automated import of CL 147028
diff --git a/tools/aapt/Resource.cpp b/tools/aapt/Resource.cpp
index b2bd9ff..2e4d0a4 100644
--- a/tools/aapt/Resource.cpp
+++ b/tools/aapt/Resource.cpp
@@ -45,13 +45,6 @@
     }
 }
 
-class ResourceTypeSet : public RefBase,
-                        public KeyedVector<String8,sp<AaptGroup> >
-{
-public:
-    ResourceTypeSet();
-};
-
 ResourceTypeSet::ResourceTypeSet()
     :RefBase(),
      KeyedVector<String8,sp<AaptGroup> >()
@@ -1055,6 +1048,7 @@
                 printf("  Writing public definitions to %s.\n", bundle->getPublicOutputFile());
             }
             table.writePublicDefinitions(String16(assets->getPackage()), fp);
+            fclose(fp);
         }
 
         NOISY(
@@ -1072,7 +1066,6 @@
             return err;
         }
     }
-
     return err;
 }