From ff8d54c2219dfe7fea3ee4445348c004274ce60e Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Sun, 29 Jan 2012 23:51:36 +0000 Subject: 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. --- htop.c | 1 + 1 file changed, 1 insertion(+) (limited to 'htop.c') 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); -- cgit v1.2.3