From: jmarcus Date: Sat, 9 Feb 2002 17:13:52 +0000 (+0000) Subject: Redo the server notification flag. Revert to having server notifications X-Git-Tag: point-backport-1-5-2~46 X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;ds=sidebyside;h=2b80e6b7495cc3471a2aed8bfcae41fd6b229dd4;p=netatalk.git Redo the server notification flag. Revert to having server notifications enabled by default, and rename the flag to -client_polling which will disable server notifications. Update documentation to reflect this new flag. --- diff --git a/ChangeLog b/ChangeLog index f92e858e..7944237a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2002-02-09 joe c + * etc/afpd/afp_options.c: Redo the -server_notif flag. Now, server + notifications are enabled by default, and specifying the -client_polling + flag will disable them. + 2002-02-06 joe c * etc/afpd/globals.h, etc/afpd/afp_options.c, etc/afpd/status.c etc/afpd/volume.c: Add a new option -server_notif to specify that diff --git a/config/afpd.conf.tmpl b/config/afpd.conf.tmpl index 93065c8e..16e4eeda 100644 --- a/config/afpd.conf.tmpl +++ b/config/afpd.conf.tmpl @@ -111,6 +111,10 @@ # -loginmesg "Message" Client will display "Message" upon logging in # (no default, same as -l "Message" on commandline) # -nodebug Switch off debugging +# -client_polling Disable server notifications. This forces the +# clients to poll every 10 seconds for directory +# updates. Note, currently this is the only way to +# get asynchronous updates. # -tickleval Specify the tickle timeout interval (in seconds). # Note, this defaults to 30 seconds, and really # shouldn't be changed. If you want to control diff --git a/doc/CONFIGURE b/doc/CONFIGURE index ee014523..5e8d230c 100644 --- a/doc/CONFIGURE +++ b/doc/CONFIGURE @@ -112,7 +112,12 @@ Miscellaneous: (no default, same as -l "Message" on command-line) -nodebug Switch off debugging + -client_polling Disable server notifications. This forces the + clients to poll every 10 seconds for directory updates. Note, + currently this is the only way to get asynchronous updates. -ticklevel Specify the tickle timeout interval (in seconds) + -timeout Specify the number of tickles to miss before tearing + down a client connection -icon Use the platform-specific icon. An example: diff --git a/etc/afpd/afp_options.c b/etc/afpd/afp_options.c index 26535e43..1ddfb384 100644 --- a/etc/afpd/afp_options.c +++ b/etc/afpd/afp_options.c @@ -1,5 +1,5 @@ /* - * $Id: afp_options.c,v 1.18 2002-02-06 21:58:50 jmarcus Exp $ + * $Id: afp_options.c,v 1.19 2002-02-09 17:13:53 jmarcus Exp $ * * Copyright (c) 1997 Adrian Sun (asun@zoology.washington.edu) * Copyright (c) 1990,1993 Regents of The University of Michigan. @@ -142,7 +142,7 @@ void afp_options_init(struct afp_options *options) options->passwdfile = _PATH_AFPDPWFILE; options->tickleval = 30; options->timeout = 4; - options->server_notif = 0; + options->server_notif = 1; options->authprintdir = NULL; options->umask = 0; #ifdef ADMIN_GRP @@ -208,6 +208,8 @@ int afp_options_parseline(char *buf, struct afp_options *options) options->transports |= AFPTRANS_DDP; if (strstr(buf, " -noddp")) options->transports &= ~AFPTRANS_DDP; + if (strstr(buf, "-client_polling")) + options->server_notif = 0; /* figure out options w/ values. currently, this will ignore the setting * if memory is lacking. */ @@ -237,9 +239,6 @@ int afp_options_parseline(char *buf, struct afp_options *options) options->timeout = 4; } } - if ((c = getoption(buf, "-server_notif"))) { - options->server_notif = 1; - } if ((c = getoption(buf, "-server_quantum"))) options->server_quantum = strtoul(c, NULL, 0);