free(opt->logconfig);
if (opt->mimicmodel && (opt->mimicmodel != save->mimicmodel))
free(opt->mimicmodel);
+ if (opt->adminauthuser && (opt->adminauthuser != save->adminauthuser))
+ free(opt->adminauthuser);
}
/* initialize options */
options->tcp_rcvbuf = 0; /* 0 means don't change OS default */
options->dsireadbuf = 12;
options->mimicmodel = NULL;
+ options->fce_fmodwait = 60; /* put fmod events 60 seconds on hold */
+ options->adminauthuser = NULL;
}
/* parse an afpd.conf line. i'm doing it this way because it's
options->flags |= OPTION_ANNOUNCESSH;
if (strstr(buf, " -noacl2maccess"))
options->flags &= ~OPTION_ACL2MACCESS;
+ if (strstr(buf, " -keepsessions")) {
+ default_options.flags |= OPTION_KEEPSESSIONS;
+ options->flags |= OPTION_KEEPSESSIONS;
+ }
/* passwd bits */
if (strstr(buf, " -nosavepassword"))
}
if ((c = getoption(buf, "-sleep"))) {
- options->sleep = atoi(c) *120;
+ options->disconnected = options->sleep = atoi(c) * 120;
if (options->sleep <= 4) {
- options->sleep = 4;
+ options->disconnected = options->sleep = 4;
}
}
fce_set_events(c);
}
+ if ((c = getoption(buf, "-fceholdfmod")))
+ options->fce_fmodwait = atoi(c);
+
if ((c = getoption(buf, "-mimicmodel")) && (opt = strdup(c)))
options->mimicmodel = opt;
+ if ((c = getoption(buf, "-adminauthuser")) && (opt = strdup(c)))
+ options->adminauthuser = opt;
+
return 1;
}
*/
static void show_version( void )
{
+ int num, i;
+
printf( "afpd %s - Apple Filing Protocol (AFP) daemon of Netatalk\n\n", VERSION );
puts( "This program is free software; you can redistribute it and/or modify it under" );
puts( "afpd has been compiled with support for these features:\n" );
- printf( " AFP3.x support:\tYes\n" );
- printf( " TCP/IP Support:\t" );
- puts( "Yes" );
+ num = sizeof( afp_versions ) / sizeof( afp_versions[ 0 ] );
+ printf( " AFP versions:\t" );
+ for ( i = 0; i < num; i++ ) {
+ printf( "%d.%d ", afp_versions[ i ].av_number/10, afp_versions[ i ].av_number%10);
+ }
+ puts( "" );
printf( " CNID backends:\t" );
#ifdef CNID_BACKEND_CDB
puts( "No" );
#endif
+ printf( " EA support:\t" );
+ puts( EA_MODULES );
+
printf( " ACL support:\t" );
#ifdef HAVE_ACLS
puts( "Yes" );
puts( "No" );
#endif
- printf( " EA support:\t" );
- puts( EA_MODULES );
-
printf( " LDAP support:\t" );
#ifdef HAVE_LDAP
puts( "Yes" );
*p = '\0';
}
+#ifdef ultrix
if (NULL == ( p = strrchr( av[ 0 ], '/' )) ) {
p = av[ 0 ];
} else {
p++;
}
+ openlog( p, LOG_PID ); /* ultrix only */
+#endif /* ultrix */
while (EOF != ( c = getopt( ac, av, OPTIONS )) ) {
switch ( c ) {
exit( 2 );
}
-#ifdef ultrix
- openlog( p, LOG_PID ); /* ultrix only */
-#else
- set_processname(p);
-#endif /* ultrix */
-
return 1;
}