--- atop-2.0.2.orig/deviate.c
+++ atop-2.0.2/deviate.c
@@ -178,6 +178,7 @@
 #include <stdio.h>
 #include <errno.h>
 #include <fcntl.h>
+#include <stdlib.h>
 #include <unistd.h>
 #include <limits.h>
 #include <memory.h>
--- atop-2.0.2.orig/procdbase.c
+++ atop-2.0.2/procdbase.c
@@ -67,7 +67,7 @@
 #include <fcntl.h>
 #include <unistd.h>
 #include <string.h>
-#include <malloc.h>
+#include <stdlib.h>
 
 #include "atop.h"
 #include "photoproc.h"
--- atop-2.0.2.orig/showgeneric.c
+++ atop-2.0.2/showgeneric.c
@@ -268,7 +268,7 @@
 #include <errno.h>
 #include <fcntl.h>
 #include <string.h>
-#include <termio.h>
+#include <termios.h>
 #include <unistd.h>
 #include <stdarg.h>
 #include <curses.h>
--- atop-2.0.2.orig/showlinux.c
+++ atop-2.0.2/showlinux.c
@@ -274,7 +274,7 @@
 #include <string.h>
 #include <errno.h>
 #include <fcntl.h>
-#include <termio.h>
+#include <termios.h>
 #include <unistd.h>
 #include <stdarg.h>
 #include <curses.h>
--- atop-2.0.2.orig/showprocs.c
+++ atop-2.0.2/showprocs.c
@@ -94,7 +94,7 @@
 #include <string.h>
 #include <errno.h>
 #include <fcntl.h>
-#include <termio.h>
+#include <termios.h>
 #include <unistd.h>
 #include <stdarg.h>
 #include <curses.h>
--- atop-2.0.2.orig/showsys.c
+++ atop-2.0.2/showsys.c
@@ -80,7 +80,7 @@
 #include <string.h>
 #include <errno.h>
 #include <fcntl.h>
-#include <termio.h>
+#include <termios.h>
 #include <unistd.h>
 #include <stdarg.h>
 #include <curses.h>