diff options
author | Eric Wong <e@80x24.org> | 2021-11-02 06:57:43 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2021-11-02 11:13:45 +0000 |
commit | bcc02b78e322f87d942459de874ba68b3fc06c39 (patch) | |
tree | c9c7e3961d07ac550fcaa4a01f57d3ab86dbb592 /script | |
parent | 2191edf5e099363a860e27d9e1b0f98ef51c6e59 (diff) | |
download | public-inbox-bcc02b78e322f87d942459de874ba68b3fc06c39.tar.gz |
I noticed a description for a new inbox had st_mode=0600.
Diffstat (limited to 'script')
-rwxr-xr-x | script/public-inbox-init | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/script/public-inbox-init b/script/public-inbox-init index 1223d47e..5de45781 100755 --- a/script/public-inbox-init +++ b/script/public-inbox-init @@ -212,6 +212,12 @@ if ($skip_docdata) { } $ibx->init_inbox(0, $skip_epoch, $skip_artnum); +my $f = "$inboxdir/description"; +if (sysopen $fh, $f, O_CREAT|O_EXCL|O_WRONLY) { + print $fh "public inbox for $address[0]\n" or die "print($f): $!"; + close $fh or die "close($f): $!"; +} + # needed for git prior to v2.1.0 umask(0077) if defined $perm; @@ -248,9 +254,3 @@ if (defined $perm) { rename $pi_config_tmp, $pi_config or die "failed to rename `$pi_config_tmp' to `$pi_config': $!\n"; undef $auto_unlink; # trigger ->DESTROY - -my $f = "$inboxdir/description"; -if (sysopen $fh, $f, O_CREAT|O_EXCL|O_WRONLY) { - print $fh "public inbox for $address[0]\n" or die "print($f): $!"; - close $fh or die "close($f): $!"; -} |