Fixed bug with calculating amount of free/used memory