Update of /cvsroot/mahogany/M/lib/imap/src/osdep/nt
In directory
sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18154/lib/imap/src/osdep/nt
Modified Files:
pmatch.c
Log Message:
treat slashes and backslashes equivalently under Windows
Index: pmatch.c
===================================================================
RCS file: /cvsroot/mahogany/M/lib/imap/src/osdep/nt/pmatch.c,v
retrieving revision 1.1.1.2
retrieving revision 1.2
diff -b -u -2 -r1.1.1.2 -r1.2
--- pmatch.c 28 Apr 2004 22:39:03 -0000 1.1.1.2
+++ pmatch.c 1 Jul 2005 14:55:50 -0000 1.2
@@ -31,5 +31,10 @@
case '%': /* non-recursive */
/* % at end, OK if no inferiors */
- if (!pat[1]) return (delim && strchr (s,delim)) ? NIL : T;
+ if (!pat[1]) switch ( delim ) {
+ case '\0': return T;
+ case '\\':
+ case '/': return !strchr (s,'\\') && !strchr (s,'/') ? T : NIL;
+ default: return strchr (s, delim) ? NIL : T;
+ }
/* scan remainder of string until delimiter */
do if (pmatch_full (s,pat+1,delim)) return T;
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Mahogany-cvsupdates mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates