law: 19. Grounds for which a candidate other than the returned candidate may he declared to have been elected.-
  If any person who has lodged an election petition has, in addition to calling in question the election of the returned candidate, claimed a declaration that he himself or any other candidate has been duly elected and the Supreme Court is of opinion that in fact the petitioner or such other candidate received a majority of the valid votes, the Supreme Court shall, after declaring the election of the returned candidate to be void, declare the petitioner or such other candidate, as the case may be, to have been duly elected: Provided that the petitioner or such other candidate shall not be declared to be duly elected if it is proved that the election of such candidate would have been void if he had been the returned candidate and a petition had been presented calling in question his election.