On 2005-10-05 16:03:38 -0400, Elliot Kendall wrote:
> I have some pesky users who begin the names of their mailboxes with -.
> This patch allows me to use mailutil with those mailboxes by giving
> the standard UNIX -- switch to indicate that no more switches should
> be parsed.
THIS patch, rather.
--
Elliot Kendall <[EMAIL PROTECTED]>
Systems Administrator
Brandeis University
diff -ur imap-2004g.orig/src/mailutil/mailutil.c
imap-2004g/src/mailutil/mailutil.c
--- imap-2004g.orig/src/mailutil/mailutil.c 2005-07-20 16:52:51.000000000
-0400
+++ imap-2004g/src/mailutil/mailutil.c 2005-07-20 16:59:09.000000000 -0400
@@ -151,14 +151,16 @@
int nargs,i;
int merge = NIL;
int ret = 1;
+ int moreswitchesp = T;
char *cmd = NIL;
char *src = NIL;
char *dst = NIL;
char *pgm = argc ? argv[0] : "mailutil";
#include "linkage.c"
for (nargs = argc ? argc - 1 : 0,args = argv + 1; nargs; args++,nargs--) {
- if (*(s = *args) == '-') { /* parse switches */
+ if (*(s = *args) == '-' && moreswitchesp) { /* parse switches */
if (!strcmp (s,"-debug") || !strcmp (s,"-d")) debugp = T;
+ else if (!strcmp (s,"--")) moreswitchesp = NIL;
else if (!strcmp (s,"-verbose") || !strcmp (s,"-v")) verbosep = T;
else if (!strcmp (s,"-rwcopy") || !strcmp (s,"-rw")) rwcopyp = T;
else if ((nargs > 1) && (!strcmp (s,"-merge") || !strcmp (s,"-m"))) {
_______________________________________________
Imap-uw mailing list
[email protected]
https://mailman1.u.washington.edu/mailman/listinfo/imap-uw