1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-10 01:48:00 +00:00
Commit Graph

6 Commits

Author SHA1 Message Date
Simon Tatham
d1eb40950c wildcard.c: allow the matched string to be a ptrlen.
The main wildcard matching code now doesn't depend on having a NUL
terminator in the string to be matched; instead it works with a pair
of pointers, one working along the string as we match, and the other
identifying the end of the string, and tests that p < target_end
before dereferencing p. User-facing entry points now allow you to pass
either an ordinary ASCIZ const char * or a ptrlen, and set up
target_end accordingly.

For the moment, the _wildcard_ parameter still has to be an ordinary
null-terminated string, but who knows, maybe that will have to change
too at some later point.
2018-10-24 19:19:56 +01:00
Simon Tatham
74cf14e4eb Add a missing null pointer check in wc_unescape, to bring it in line
with the usage comment saying you're allowed to pass NULL to find out
only the return value. No caller actually does pass NULL at the
moment.

[originally from svn r9920]
2013-07-14 10:46:17 +00:00
Jacob Nevins
bb6532810b Add notes on our globs' incompatibilities with POSIX
[originally from svn r4149]
2004-04-27 12:52:34 +00:00
Ben Harris
2f1e76e843 Include putty.h to get prototypes for exported functions.
[originally from svn r2486]
2003-01-05 23:38:11 +00:00
Ben Harris
78acf8edb8 Commas at the end of enumerator lists aren't allowed.
[originally from svn r2466]
2003-01-05 14:18:00 +00:00
Simon Tatham
0da98d052d Implemented a simple wildcard matching engine, and used it to
restore remote wildcard capability in sftp-style PSCP.

[originally from svn r1209]
2001-08-27 10:17:41 +00:00