Here is the psuedocode of the Max-Heapify algorithm :
MAX-HEAPIFY(A, i)
1. l <- Left(i)
2. r <- Right(i)
3. if l <= heap-size[A] and A[l] > A[i]
4. largest <- l
5. else largest <- i
[...]
What's the purpose to verify that the index of the left heap is smaller equal than the size of heap A given in input ?