bgarrigues pushed a commit to branch master
in repository groff.

commit 0d4df60290dc22e3975c803833219cd853b0827e
Author: Bertrand Garrigues <[email protected]>
AuthorDate: Sun Oct 18 01:44:24 2020 +0200

    hpftodit: incorrect 'delete' after new[]
    
    * src/utils/hpftodit/hpftodit.cpp (output_font_name): use 'delete[]'.
    
    Fixes bug #55331. Found by David Binderman, fixed by Ingo Schwarze.
---
 ChangeLog                       | 8 ++++++++
 src/utils/hpftodit/hpftodit.cpp | 2 +-
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 5b70e0c..1ceb05a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
 2020-10-18 Bertrand Garrigues <[email protected]>
 
+    hpftodit: incorrect 'delete' after new[]
+
+    * src/utils/hpftodit/hpftodit.cpp (output_font_name): use 'delete[]'.
+
+    Fixes bug #55331. Found by David Binderman, fixed by Ingo Schwarze.
+
+2020-10-18 Bertrand Garrigues <[email protected]>
+
        preconv: don't use libuchardet if input is stdin
 
        * src/preproc/preconv/preconv.cpp (do_file): don't call
diff --git a/src/utils/hpftodit/hpftodit.cpp b/src/utils/hpftodit/hpftodit.cpp
index 1298955..c45f226 100644
--- a/src/utils/hpftodit/hpftodit.cpp
+++ b/src/utils/hpftodit/hpftodit.cpp
@@ -574,7 +574,7 @@ output_font_name(File &f)
     ;
   *(p + 1) = '\0';
   printf("# %s\n", font_name);
-  delete font_name;
+  delete[] font_name;
 }
 
 static void

_______________________________________________
Groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to