}
}
-print join(" ", @newmods),"\n";
-
# read_file(file, array)
# Fill an associative array with name=value pairs from a file
sub read_file
local $rmask;
vec($rmask, fileno(SOCK), 1) = 1;
local $sel = select($rmask, undef, undef, 60);
- last if ($sel <= 0);
+ if ($sel <= 0) {
+ print STDERR "fastrpc: session timed out\n"
+ if ($gconfig{'rpcdebug'});
+ last;
+ }
local $line = <SOCK>;
last if (!$line);
# execute a function
print STDERR "fastrpc: call $arg->{'module'}::$arg->{'func'}(",join(",", @{$arg->{'args'}}),")\n" if ($gconfig{'rpcdebug'});
local @rv;
+ local $main::error_must_die = 1;
eval {
@rv = &foreign_call($arg->{'module'},
$arg->{'func'},
The configuration check process now ensures that the system is setup to use itself as a DNS server, so that newly created domains will resolve.
Added an option to the scheduled backup page to only send an email report when the backup fails, and an option to send email to domain owners as well.
When a virtual server with anonymous FTP is created, the ProFTPd user (typically ftp) is added to the domain's Unix group. This allows anonymous FTP to work even when the domain's home directory is not world-readable.
+---- Changes since 3.41 ----
+In the server templates pages under Default domain owner limits, added a section for specifying the features that can be used by the server owner. Previously, these were always automatically determined based on the features initially enabled when the domain was created.
}
# enable or disable
-local $enable = &has_command("enable");
+local $enable = &has_command("cupsenable") || &has_command("enable");
+local $disable = &has_command("cupsdisable") || &has_command("disable");
if ($prn{'enabled'}) { $cmd = "$enable $esc"; }
elsif ($prn{'enabled_why'}) {
local $wesc = quotemeta($prn{'enabled_why'});
- $cmd = "$enable $esc ; disable -r $wesc $esc";
+ $cmd = "$enable $esc ; $disable -r $wesc $esc";
}
-else { $cmd = "$enable $esc ; disable $esc"; }
+else { $cmd = "$enable $esc ; $disable $esc"; }
$out = &backquote_logged("$cmd 2>&1");
# accepting or rejecting requests
push(@icons, "images/list.gif");
}
if (@links) {
- print "<a href='create_form.cgi'>$text{'index_add'}</a>\n";
+ @crlinks = ( "<a href='create_form.cgi'>$text{'index_add'}</a>" );
if (@links) {
- print " \n";
- print "<a href='digest_form.cgi'>$text{'index_digest'}</a>\n";
+ push(@crlinks, "<a href='digest_form.cgi'>$text{'index_digest'}</a>");
+ }
+ if ($access{'create'}) {
+ print &ui_links_row(\@crlinks);
}
- print "<br>\n";
&icons_table(\@links, \@titles, \@icons, 5);
}
else {
print "<b>$text{'index_none'}</b>.<p>\n";
}
if ($access{'create'}) {
- print "<a href='create_form.cgi'>$text{'index_add'}</a>\n";
- if (@links) {
- print " \n";
- print "<a href='digest_form.cgi'>$text{'index_digest'}</a>\n";
- }
- print "<p>\n";
+ print &ui_links_row(\@crlinks);
}
if ($access{'global'}) {
index_owner=Owner email address
index_setup=Setup Aliases
index_none=You have no mailing lists defined
-index_add=Add a new mailing list
-index_digest=Add a new digest list
+index_add=Add a new mailing list.
+index_digest=Add a new digest list.
index_global=Edit Majordomo Options
index_globaldesc=Edit global Majordomo options that apply to all mailing lists
index_return=mailing lists
sub fstype_name
{
local(%fsmap);
-%fsmap = ("ext2","Linux Native Filesystem",
- "ext3","New Linux Native Filesystem",
+%fsmap = ("ext2","Old Linux Native Filesystem",
+ "ext3","Linux Native Filesystem",
"minix","Minix Filesystem",
"msdos","MS-DOS Filesystem",
"nfs","Network Filesystem",
if ($access{'indexes'}) {
@indexes = &list_indexes($in{'db'});
}
-if ($mysql_version >= 5 && $access{'views'}) {
+if (&supports_views() && $access{'views'}) {
@views = &list_views($in{'db'});
}
print "$text{'session_prefix'}\n";
print "<form action=$gconfig{'webprefix'}/session_login.cgi method=post>\n";
print "<input type=hidden name=page value='".&html_escape($in{'page'})."'>\n";
-print "<table border width=40% class='loginform formsection'>\n";
+print "<table border width=40% class='loginform'>\n";
print "<tr $tb> <td><b>$text{'session_header'}</b></td> </tr>\n";
print "<tr $cb> <td align=center><table cellpadding=3>\n";
if ($gconfig{'realname'}) {
if ($config{'pinger'}) {
# Call a ping command
local $cmd = $config{'pinger'} eq "linux" ?
- "ping -c 1 -t 1" : $config{'pinger'};
+ "ping -c 1 -w $wait" : $config{'pinger'};
local $rv = system("$cmd ".quotemeta($_[0]->{'host'}).
" >/dev/null 2>&1 </dev/null");
return { 'up' => $rv ? 0 : 1 };
# Shows a form for adding a new zone
require './zones-lib.pl';
+do 'forms-lib.pl';
use Socket;
&ReadParse();
$p = new Webmin::Page(undef, $text{'create_title'}, "create");
# Actually creates a new zone
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
&error_setup($text{'create_err'});
&foreign_require("time", "time-lib.pl");
# Show a form for editing a generic attribute or adding one
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Show a form for editing a filesystem or adding one
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Show a form for editing a network interface or adding one
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Show a form for editing a package directory or adding one
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Show a form for editing a resource control or adding one
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Shows the details of one zone, with links to make changes
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
+use Webmin::All;
+
# get_zone_form(&in, &zinfo)
# Returns a form for editing a zone
sub get_zone_form
# Shows all zones, with links to add more
require './zones-lib.pl';
+do 'forms-lib.pl';
$p = new Webmin::Page(undef, $module_info{'desc'}, "intro", 1, 1);
$zn = &get_current_zone();
# Update, add or delete a generic attribute
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Update, add or delete a filesystem
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Update, add or delete a network interface
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Update, add or delete an inherited package directory
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Update, add or delete a resource control
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
# Update, reboot or delete a zone
require './zones-lib.pl';
+do 'forms-lib.pl';
&ReadParse();
$zinfo = &get_zone($in{'zone'});
$zinfo || &error($text{'edit_egone'});
do '../web-lib.pl';
&init_config();
do '../ui-lib.pl';
-do 'forms-lib.pl';
-use Webmin::All;
&foreign_require("net", "net-lib.pl");
&foreign_require("mount", "mount-lib.pl");