Fixed a bug in heap linked list

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>