<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/65256>65256</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
llvm-cov show: inconsistent output directory & file permissions
</td>
</tr>
<tr>
<th>Labels</th>
<td>
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
dkl
</td>
</tr>
</table>
<pre>
Hi,
`llvm-cov show` appears to use hard-coded permissions 0770 for output directories and 0666 for output files. For the HTML report, this means that `index.html` is world readable, but the additional HTML files for individual source files in the `coverage/` subdirectory are not. In our case, a build, which produced coverage data and invoked `llvm-cov show`, ran as root in a Docker container, and the non-root CI system could only collect a part of the report, not all of it.
This can of course easily be worked around by invoking `chmod`, but perhaps it would make sense for `llvm-cov show` to produce better permissions by default. Since it makes the files world readable already, could it do the same for directories? Or could it respect the environment umask?
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxsk8tu6zgPx59G2RANfEnceuFFvxbBOcA3mMWcF6AlNtZUFg2RSidvP5DSou3gbGwBvP35I4ki_hyJJnP8nzk-7zDrwmlyr2E3s7tOP7zpnkzzbJrH9-_QhHBZ7yxfQBZ-M0MDuG2ESUAZshAsmNydZUcONkqrF_EcBZr7-wZeOAFn3bKC84mscvIkgNFBMwzDV_uLDyR7OHECXQh-_Prj_5Bo46SmewJdvMBKGAV0QQUzND46-me_6BqKKC_wxik4SIQO50Alas5ak6FzXj1HDLe8tVYt7qPzF-8yBhDOydK7zccaaIbG8oUSnsl0p1JH8vzRyRUwEUTWPfyMwDmBRal1EebsgyvPt8XbBbbELlty8JENHCpWDj5e-JUc_IZ0iU8YAQUSsxZRCM9sXymB5ajoI6VaL7oqN3K8q55PP0GuorSC5RwccAxXsBwCWQWEDZMCv9SYT8aRFTCEYvC6_7oFvwp9i7GYLOckBITiwxVmKtiLfkyco4P5euvIx3Olt6zs3lsp09goLbgJeIW3qmzFVwKhKFTn8bt9U_7gBzOpUvq2Z_MVHL1gDrqHv3y0VHKXrFLbu43z-2oAhvK8FlE3Pl7BcfUXXG9Kvuyr6U_wZ_p0TSRbAVn8KV584rhSVMgryqvpTzs39W7sR9zR1A5j_9CN47HfLdOM3WGe20NDOI72hZrm4UDYPhyP7TC2ttn5qWu6vhmbQ9u1Y9vvZ9v3Q09ji3PXHuy9OTS0og_7QmnP6bzzIpmm4dgdh13AmYJ8HHeaKso5n8UcmuBF5TNMvQaavrPuH8FHy1G8aOnnP5d7BdMNFejXAexyCtOiuonpH8uRdKez1yXPe8ur6U6lxPvvbkv8N1k13amqFtOdqvB_AwAA___G2JCu">