summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfukachan <fukachan>2002-12-18 04:42:37 +0000
committerfukachan <fukachan>2002-12-18 04:42:37 +0000
commit5b6e38b6f93bb9ba39d35328d09d58440242ffdc (patch)
tree914d10bada51300972a1d31656008b9e68d73d6b
parent0e4c9e44f97a6705f3674b5e06dd6befe7514339 (diff)
downloadfml8-5b6e38b6f93bb9ba39d35328d09d58440242ffdc.tar.gz
fml8-5b6e38b6f93bb9ba39d35328d09d58440242ffdc.tar.bz2
fml8-5b6e38b6f93bb9ba39d35328d09d58440242ffdc.zip
clean up comments.
$fh->close()
-rw-r--r--fml/lib/FML/Process/Addr.pm44
1 files changed, 22 insertions, 22 deletions
diff --git a/fml/lib/FML/Process/Addr.pm b/fml/lib/FML/Process/Addr.pm
index f2d37fb4..736b754e 100644
--- a/fml/lib/FML/Process/Addr.pm
+++ b/fml/lib/FML/Process/Addr.pm
@@ -3,14 +3,14 @@
# Copyright (C) 2001,2002 Ken'ichi Fukamachi
# All rights reserved.
#
-# $FML: Addr.pm,v 1.1 2002/11/07 10:53:51 fukachan Exp $
+# $FML: Addr.pm,v 1.2 2002/11/10 14:50:19 fukachan Exp $
#
package FML::Process::Addr;
-use vars qw($debug @ISA @EXPORT @EXPORT_OK);
use strict;
use Carp;
+use vars qw($debug @ISA @EXPORT @EXPORT_OK);
use FML::Log qw(Log LogWarn LogError);
use FML::Config;
@@ -20,7 +20,7 @@ use FML::Process::Kernel;
=head1 NAME
-FML::Process::Addr -- fmladdr main functions
+FML::Process::Addr -- fmladdr, which show all aliases (accounts + aliases).
=head1 SYNOPSIS
@@ -32,6 +32,9 @@ FML::Process::Addr -- fmladdr main functions
FML::Process::Addr provides the main function for C<fmladdr>.
+C<fmladdr> command shows all aliases (accounts + aliases) but
+C<fmlalias> command shows only aliases without accounts.
+
See C<FML::Process::Flow> for the flow detail.
=head1 METHODS
@@ -43,6 +46,10 @@ It make a C<FML::Process::Kernel> object and return it.
=head2 C<prepare($args)>
+load config files and fix @INC.
+
+=head2 C<verify_request($args)>
+
dummy.
=cut
@@ -61,7 +68,7 @@ sub new
}
-# Descriptions: dummy
+# Descriptions: load config files and fix @INC.
# Arguments: OBJ($curproc) HASH_REF($args)
# Side Effects: none
# Return Value: none
@@ -110,12 +117,9 @@ sub verify_request
=head2 C<run($args)>
-the top level dispatcher for C<fmlconf> and C<fmladdr>.
+the top level dispatcher for C<fmladdr>.
-It kicks off internal function
-C<_fmlconf($args)> for C<fmlconf>
- and
-C<_fmladdr($args)> for fmladdr.
+It kicks off C<_fmladdr($args)> for fmladdr.
NOTE:
C<$args> is passed from parrent libexec/loader.
@@ -185,23 +189,16 @@ _EOF_
=head2 C<_fmladdr($args)> (INTERNAL USE)
-switch of C<fmladdr> command.
-It kicks off <FML::Command::$command> corrsponding with
-C<@$argv> ( $argv = $args->{ ARGV } ).
-
-C<Caution:>
-C<$args> is passed from parrent libexec/loader.
-We construct a new struct C<$command_args> here to pass parameters
-to child objects.
-C<FML::Command::$command> object takes them as arguments not pure
-C<$args>. It is a little mess. Pay attention.
+show all aliases (accounts + aliases).
+show only accounts if -n option specified.
See <FML::Process::Switch()> on C<$args> for more details.
=cut
-# Descriptions: fmladdr top level dispacher
+# Descriptions: show all aliases (accounts + aliases).
+# show only accounts if -n option specified.
# Arguments: OBJ($curproc) HASH_REF($args)
# Side Effects: load FML::Command::command module and execute it.
# Return Value: none
@@ -215,7 +212,7 @@ sub _fmladdr
my $eval = $config->get_hook( 'fmladdr_run_start_hook' );
if ($eval) { eval qq{ $eval; }; LogWarn($@) if $@; }
- # -n
+ # show only accounts if -n option specified.
my $mode = $args->{ options }->{ n } ? 'fmlonly' : 'all';
use FML::MTAControl;
@@ -225,6 +222,8 @@ sub _fmladdr
mode => $mode,
});
+ # XXX-TODO: all unix system has /etc/passwd ?
+ # XXX-TODO: we should implement another mothod to get accounts.
# read addresses from password file
if (-f "/etc/passwd") {
use FileHandle;
@@ -239,7 +238,8 @@ sub _fmladdr
$aliases->{ $user } = "$user (LOCAL USER)";
}
}
- close($fh);
+
+ $fh->close();
}
}