X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/4c4a2962097e618480d37ffffbb2a2714a6ecbf5..d0f2bbb83e0c9a1b4264eeadfc2d53fb5aafb657:/options.c diff --git a/options.c b/options.c index fa3bdcd6..6ee3e01e 100644 --- a/options.c +++ b/options.c @@ -3,7 +3,7 @@ * * Copyright (C) 1998-2001 Andrew Tridgell * Copyright (C) 2000, 2001, 2002 Martin Pool - * Copyright (C) 2002-2009 Wayne Davison + * Copyright (C) 2002-2010 Wayne Davison * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -603,7 +603,7 @@ static void print_rsync_version(enum logcode f) rprintf(f, "%s version %s protocol version %d%s\n", RSYNC_NAME, RSYNC_VERSION, PROTOCOL_VERSION, subprotocol); - rprintf(f, "Copyright (C) 1996-2009 by Andrew Tridgell, Wayne Davison, and others.\n"); + rprintf(f, "Copyright (C) 1996-2010 by Andrew Tridgell, Wayne Davison, and others.\n"); rprintf(f, "Web site: http://rsync.samba.org/\n"); rprintf(f, "Capabilities:\n"); rprintf(f, " %d-bit files, %d-bit inums, %d-bit timestamps, %d-bit long ints,\n", @@ -1780,12 +1780,17 @@ int parse_arguments(int *argc_p, const char ***argv_p) } if (protect_args < 0) { + if (am_server) + protect_args = 0; + else if ((arg = getenv("RSYNC_PROTECT_ARGS")) != NULL && *arg) + protect_args = atoi(arg) ? 1 : 0; + else { #ifdef RSYNC_USE_PROTECTED_ARGS - if (!am_server) protect_args = 1; - else -#endif +#else protect_args = 0; +#endif + } } if (human_readable > 1 && argc == 2 && !am_server) {