Malaysia edge Pakistan in Azlan Shah match