From b54d2dde407921caa7561dde6b45831ba93d0840 Mon Sep 17 00:00:00 2001 From: Hisham Date: Tue, 2 Feb 2016 15:53:02 +0100 Subject: Check for failure in allocations. --- MainPanel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'MainPanel.c') diff --git a/MainPanel.c b/MainPanel.c index 336cfa46..f9b45d64 100644 --- a/MainPanel.c +++ b/MainPanel.c @@ -190,7 +190,7 @@ PanelClass MainPanel_class = { MainPanel* MainPanel_new() { MainPanel* this = AllocThis(MainPanel); Panel_init((Panel*) this, 1, 1, 1, 1, Class(Process), false, FunctionBar_new(MainFunctions, NULL, NULL)); - this->keys = calloc(KEY_MAX, sizeof(Htop_Action)); + this->keys = xCalloc(KEY_MAX, sizeof(Htop_Action)); this->inc = IncSet_new(MainPanel_getFunctionBar(this)); Action_setBindings(this->keys); -- cgit v1.2.3