WildCard Key

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Hi,

I have a std::list that holds a list of disallowed filenames. So when
the client creates a file, the service checks if it's in this list and
if so, it deletes the file. Currently, it's fast and efficient, in a
second, I can check if the key (the filename) exists in the list and
act accordingly if so.

But I have a new need to support filenames based on wildcards. So the
list may contain notepad*.exe and is supposed to block anything that
matches.

Any ideas of an efficient way to do this ? The only way I can think of
now is to loop through the entire list and compare each value.... but
i'm afraid it'll really hurt performance, the list could be potentially
long.

Thanks for any tips!

Ben

.



Relevant Pages

  • Re: rsync / Include only
    ... [using rsync to sync only matched files] ... client: nothing to do: perhaps you need to specify some filenames or ...
    (comp.os.linux.misc)
  • Re: FTP client to understand ODS-5 volumes
    ... But how can an FTP client be expected to convert between the filename ... The idea of having a common intermediate representation for filenames is ... Trivial Virtual File System implemented in increasingly many FTP clients ... ODS5 server, or any other file system, the client and server should both ...
    (comp.os.vms)
  • Samba - DOS Short Filenames
    ... There are no problems with long filenames. ... I get the following when creating new shared files on the Windows Client: ... at least the first six characters are the same as the long name. ...
    (RedHat)
  • Re: rsync / Include only
    ... [using rsync to sync only matched files] ... client: nothing to do: perhaps you need to specify some filenames or ...
    (comp.os.linux.misc)
  • Re: HP 49G+ connectivity kit: cant install
    ... I was working on file-server software for a client. ... so we began to look at ways of optimising NTFS performance. ... filenames switched off, the 16-bit installer presumably couldn't find ... So, I'm sorry for having ranted about the connection kit installer, ...
    (comp.sys.hp48)