~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/cached_directory.cc

update

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
#include <limits.h>
38
38
 
39
39
#include <drizzled/cached_directory.h>
 
40
#include <drizzled/util/find_ptr.h>
40
41
 
41
42
using namespace std;
42
43
 
133
134
    if (not allowed_exts.empty())
134
135
    {
135
136
      char *ptr= rindex(result->d_name, '.');
136
 
 
137
 
      if (ptr)
 
137
      if (ptr && allowed_exts.count(ptr))
138
138
      {
139
 
        set<string>::iterator it;
140
 
        it= allowed_exts.find(ptr);
141
 
 
142
 
        if (it != allowed_exts.end())
143
 
        {
144
 
          entries.push_back(new Entry(result->d_name));
145
 
        }
 
139
        entries.push_back(new Entry(result->d_name));
146
140
      }
147
141
    }
148
142
    else