Fixed wrong address calculation