The respondent is entitled to, after the entry into legal force of the judgment on refusal of the claim, claim from the plaintiff compensation of the losses caused to him by securing the claim by presenting the claim to the same court.