tabselectect - Force a tab

tabselectect - Force a tab

With :
jQuery 1.4.2
jQuery-ui-1.8rc3 

I want, when selecting a new tab, if validation of the current tab fails, force the return to tab(0)
But the following code loops after line 8 switching the tabselect event
How can I write tis to avoid the loop ?

  1.   $Onglets = $('#onglets').tabs();
  2.     $('#onglets').bind('tabsselect', function(){
  3.         var $curTab = $Onglets.tabs('option', 'selected');
  4.         var $isValide = ...//form validation returning true or false
  5.         if ((!$isVvalide) && ($curTab != 0)) {
  6.             //Revenir à la page générale
  7.             alert ('Forced Tab 0')
  8.             $Onglets.tabs('select', 0);
  9.         }
  10.     });
Thanks for your help