]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
auth: initialized uninitialized variable, don't free pts we don't own
authorSage Weil <sage@newdream.net>
Fri, 26 Mar 2010 22:46:52 +0000 (15:46 -0700)
committerSage Weil <sage@newdream.net>
Fri, 26 Mar 2010 22:57:17 +0000 (15:57 -0700)
src/auth/ExportControl.cc

index a8ed5e0aa28069b4fc03b4e915d33b85b263ed02..e33c4bedf91832cd3efe14fc26f35a453cbd24d8 100644 (file)
@@ -44,7 +44,7 @@ class Subnet
   
   void parse(const char *str);
 public:
-  Subnet(const char *str) {
+  Subnet(const char *str) : orig_str(NULL) {
     valid = false;
     parse(str);
   }
@@ -155,14 +155,6 @@ public:
   GroupEntry(Subnet *subnet);
   GroupEntry(GroupEntry *);
   ~GroupEntry() {
-    for (vector<Subnet*>::iterator p = subnets.begin();
-        p != subnets.end();
-        p++)
-      delete *p;
-    for (vector<GroupEntry*>::iterator p = groups.begin();
-        p != groups.end();
-        p++)
-      delete *p;
   }
 
   void parse_addr_line(const char *str);