Answer
(Fatwa: 1092/1092=M/1430)
Performing salah behind an imam of other maslak is permissible if the imam cares for the Hanafi Maslak in regard to the fardh and wajib acts. For example, he makes wudhu after occurring the things which invalidate wudhu according to Hanafi Fiqh like blood etc. If it is known certainly that the imam does not care for the same, so one should not perform salah behind him:
أما الاقتداء بالمخالف في الفروع کالشافعي فیجوز ما لم یعلم منہ ما یفسد الصلاۃ علی اعتقاد المقتدي، علیہ الإجماع (الشامي)
Allah (Subhana Wa Ta’ala) knows Best
Darul Ifta,
Darul Uloom Deoband