<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/69728>69728</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            How to turn off memcpy and memset warnings in clang-tidy?
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang-tidy
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          fefe17
      </td>
    </tr>
</table>

<pre>
    clang-tidy keeps giving me warnings that I should be using memset_s instead of memset.

> note: Call to function 'memset' is insecure as it does not provide security checks introduced in the C11 standard. Replace with analogous functions that support length arguments or provides boundary checks such as 'memset_s' in case of C11

If you look closely and carefully you will find that memset takes a length argument and does boundary checking with it. The warning is at least misleading and could even be said to be factually wrong.

Furthermore, the current glibc release does not have memset_s, and rightfully so, because Annex K is optional.

Please give me a config file where I can remove these warnings from clang-tidy globally.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxcU8-O8yYQfxp8GW1k42QTH3zY5mvUVS9V1funMYwxDQaLgaR5-wonTXZ7sSVg5vdvBpmt8US92P0idj8qzGkKsR9ppGZfDUHfeuXQm7dk9Q3ORAuDsRfrDcwEV4zeesOQJkzwCTyF7DQMBJnvT2am9JPBek6EGsL4ONuI-oeoPx7f9lfwIZFoP-CIzkEKMGavkg0ehNzfS4Tcg11bkcqRABlsAh2ISzEsMVysJlhvbbqBmkidy_sUg86KNFgPaSI4Ng1wQq8x6g38SYtDRXC1aQL06IIJmZ_4D22clyXEBI68Ke-iyTP5xBDif8gMQ8il6ROas5oKzaeEn7yK8KCQqZhxbJqvRnyOcAsZXAhnUC4wuRug16Aw0pidu63XV-scjNbrO7V7a0h4Jgb8P8O1fjXpO7sSzyrZpg38NT2zLBZj0YmcYLbsCHU5Xmms6dKFfImY0eqS1EAwokoZC79rDN58C_eUY5ooziGSkMc1AJVjLNSMs4OCSAWMXklOeCF4GXZcsaM1U7p7wKEcDqQwM8GH9_QP_F54h6Ukhu4b_h_37sauTQFBBT9aA6N1BNeJIsEnKPQQaQ4XKgT5y2SPMczwZQWMC0NRuql03-qu7bCivnnv9oe629dNNfV00KSG3XbAg5S7Rh_a3TjUnZKy224bNVS2l7Vsm1rWTbs9yGazpVrWHR0aLYf33aER25pmtG7j3GXehGgqy5ypf-_28lA5HMjxurBSvpgJKcsCx74UvQ3ZsNjWznLiV5tkk6P-t3AtuaUcPYRx3Ui13AftMUtP9WVUXwjtqcrR9VNKC4v2Q8iTkCdj05SHjQqzkKeC9Pi9LTH8TSoJeVrZs5CnVcC_AQAA___p0ogQ">