aboutsummaryrefslogtreecommitdiffstats
path: root/debian/patches/gcc10.patch
blob: 5487ffb96a35b194150ab9685d21a69c7ca4fa77 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
Description: Avoid FTBFS with GCC 10
 Initialize some pointers in CRT.c so that CRT.h is
 generated with the appropriate 'extern' keywords
Bug: https://github.com/hishamhm/htop/issues/986
Bug-Debian: https://bugs.debian.org/957344
Author: Graham Inggs <ginggs@debian.org>
Last-Update: 2020-07-02

--- a/CRT.c
+++ b/CRT.c
@@ -171,7 +171,7 @@
 
 int CRT_delay = 0;
 
-int* CRT_colors;
+int* CRT_colors = NULL;
 
 int CRT_colorSchemes[LAST_COLORSCHEME][LAST_COLORELEMENT] = {
    [COLORSCHEME_DEFAULT] = {
@@ -537,13 +537,13 @@
 
 int CRT_scrollWheelVAmount = 10;
 
-char* CRT_termType;
+char* CRT_termType = NULL;
 
 // TODO move color scheme to Settings, perhaps?
 
 int CRT_colorScheme = 0;
 
-void *backtraceArray[128];
+void *backtraceArray[128] = { NULL };
 
 static void CRT_handleSIGTERM(int sgn) {
    (void) sgn;

© 2014-2024 Faster IT GmbH | imprint | privacy policy