summaryrefslogtreecommitdiffstats
path: root/htop.c
diff options
context:
space:
mode:
authorHisham Muhammad <hisham@gobolinux.org>2012-01-29 23:51:36 +0000
committerHisham Muhammad <hisham@gobolinux.org>2012-01-29 23:51:36 +0000
commitff8d54c2219dfe7fea3ee4445348c004274ce60e (patch)
tree620093b45b94bc01b418b2cb21b01e5ff17ee759 /htop.c
parent8b73d11ac68565d458e4942c1bd9b2f119565489 (diff)
Extra check if Process_getAffinity fails.
I could not reproduce the crash in current SVN (I've been adding checks for problems like this), but the sanity check looks correct. Thanks to Cybjit. Closes #3481053.
Diffstat (limited to 'htop.c')
-rw-r--r--htop.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/htop.c b/htop.c
index e2150a75..dda99c8f 100644
--- a/htop.c
+++ b/htop.c
@@ -772,6 +772,7 @@ int main(int argc, char** argv) {
break;
Affinity* affinity = Process_getAffinity((Process*) Panel_getSelected(panel));
+ if (!affinity) break;
Panel* affinityPanel = AffinityPanel_new(pl, affinity);
Affinity_delete(affinity);

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