Correctness of Knight Move

http://www.codechef.com/viewsolution/4493609 I am getting WA.missing some corner cases but cant find out
so plz help me .qstn http://www.codechef.com/problems/KNIGHTMV

Thank you