<p></p>
<p><b>@b4n</b> requested changes on this pull request.</p>

<p>The C standard forbids zero-size arrays.  Yes, <a href="https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html" rel="nofollow">GCC</a> and Clang do allow them as an extension (yet it's not <em>truly</em> 0-sized, but basically a VLA), GCC even discourages usage in your use case:</p>
<blockquote>
<p>Declaring zero-length arrays [anywhere but as the last member of a structure], including as interior members of structure objects or as non-member objects, is discouraged</p>
</blockquote>
<p>At any rate, it's not valid ISO C, so any compiler would be right to forbid it.  And both GCC and Clang are unhappy about them when passed <code>-pedantic</code> (GCC: <em>error: zero or negative size array ‘foo’</em>, CLang: <em>warning: zero size arrays are an extension [-Wzero-length-array]</em>).</p>
<hr>
<p>It's sad Clang doesn't see that the <code>NULL</code> check makes its warning moot, but the fix you propose is not OK as it's not valid C -- and thus likely rejected (rightly) by some compilers (I would guess MSVC might not like it, and maybe some other less common ones).</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/geany/geany/pull/2889#pullrequestreview-746683433">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAIOWJ2AYXMZQS4BPXFIRZTUAPLMVANCNFSM5DOZPAPQ">unsubscribe</a>.<br />Triage notifications on the go with GitHub Mobile for <a href="https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675">iOS</a> or <a href="https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub">Android</a>.
<img src="https://github.com/notifications/beacon/AAIOWJ5YZKAWA6HTPRTCUKLUAPLMVA5CNFSM5DOZPAP2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOFSAXYKI.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/geany/geany/pull/2889#pullrequestreview-746683433",
"url": "https://github.com/geany/geany/pull/2889#pullrequestreview-746683433",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>