From fe4896873b1289afac0812c91f8ea4d925292f78 Mon Sep 17 00:00:00 2001 From: Ilya Lysenkov Date: Wed, 2 Jun 2010 05:39:29 +0000 Subject: [PATCH] Fixed a potential memory leak in OneWayDescriptorBase hierarchy. --- modules/features2d/include/opencv2/features2d/features2d.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/features2d/include/opencv2/features2d/features2d.hpp b/modules/features2d/include/opencv2/features2d/features2d.hpp index c54b5f6723..f77275cac3 100644 --- a/modules/features2d/include/opencv2/features2d/features2d.hpp +++ b/modules/features2d/include/opencv2/features2d/features2d.hpp @@ -1030,7 +1030,7 @@ public: int pca_dim_high = 100, int pca_dim_low = 100); - ~OneWayDescriptorBase(); + virtual ~OneWayDescriptorBase(); // Allocate: allocates memory for a given number of descriptors void Allocate(int train_feature_count); @@ -1189,7 +1189,7 @@ public: const string &train_path = string (), const string &images_list = string (), int pyr_levels = 1); - ~OneWayDescriptorObject(); + virtual ~OneWayDescriptorObject(); // Allocate: allocates memory for a given number of features // - train_feature_count: the total number of features