2 # Update a manually edited config file
4 require './bind8-lib.pl';
5 &error_setup($text{'manual_err'});
6 $access{'defaults'} || &error($text{'manual_ecannot'});
10 $conf = &get_config();
11 @files = &get_all_config_files($conf);
12 &indexof($in{'file'}, @files) >= 0 || &error($text{'manual_efile'});
13 $in{'data'} =~ s/\r//g;
14 if ($in{'file'} eq $files[0]) {
15 $in{'data'} =~ /\S/ || &error($text{'manual_edata'});
19 &open_lock_tempfile(DATA, ">".&make_chroot($in{'file'}));
20 &print_tempfile(DATA, $in{'data'});
21 &close_tempfile(DATA);
23 &webmin_log("manual", undef, $in{'file'});