logo

oasis

Own branch of Oasis Linux (upstream: <https://git.sr.ht/~mcf/oasis/>) git clone https://anongit.hacktivis.me/git/oasis.git

0006-Remove-unintended-use-of-VLA.patch (928B)


  1. From ba9aa51428c55309c307c70c02706777a0403f13 Mon Sep 17 00:00:00 2001
  2. From: Michael Forney <mforney@mforney.org>
  3. Date: Tue, 21 Dec 2021 13:24:55 -0800
  4. Subject: [PATCH] Remove unintended use of VLA
  5. ---
  6. services/authzone.c | 4 ++--
  7. 1 file changed, 2 insertions(+), 2 deletions(-)
  8. diff --git a/services/authzone.c b/services/authzone.c
  9. index e83af533..918874cc 100644
  10. --- a/services/authzone.c
  11. +++ b/services/authzone.c
  12. @@ -7553,8 +7553,8 @@ static int zonemd_simple_domain(struct auth_zone* z, int hashalgo,
  13. struct secalgo_hash* h, struct auth_data* node,
  14. struct regional* region, struct sldns_buffer* buf, char** reason)
  15. {
  16. - const size_t rrlistsize = 65536;
  17. - struct auth_rrset* rrlist[rrlistsize];
  18. + struct auth_rrset* rrlist[65536];
  19. + const size_t rrlistsize = sizeof(rrlist) / sizeof(*rrlist);
  20. size_t i, rrnum = 0;
  21. /* see if the domain is out of scope, the zone origin,
  22. * that would be omitted */
  23. --
  24. 2.34.1