Program: 187523
Project: 187523
Buggy source:
/** 
 * Is called when player rightclicks this MyPet return: true: there was a reaction on rightclick false: no reaction on rightclick
 */
public boolean handlePlayerInteraction(EntityHuman entityhuman){
  ItemStack itemStack=entityhuman.inventory.getItemInHand();
  Player owner=this.getOwner().getPlayer();
  applyLeash();
  if (itemStack == null || itemStack.id == 0) {
    if (Ride.RIDE_ITEM == 0 && myPet.getSkills().isSkillActive("String_Node_Str") && canMove()) {
      if (Permissions.hasExtended(owner,"String_Node_Str")) {
        ((CraftPlayer)owner).getHandle().setPassengerOf(this);
        return true;
      }
 else {
        getMyPet().sendMessageToOwner(Locales.getString("String_Node_Str",myPet.getOwner().getLanguage()));
      }
    }
    return false;
  }
  if (isMyPet() && myPet.getOwner().equals(entityhuman)) {
    if (myPet.getSkills().isSkillActive("String_Node_Str")) {
      if (itemStack.id == Ride.RIDE_ITEM && canMove()) {
        if (Permissions.hasExtended(owner,"String_Node_Str")) {
          ((CraftPlayer)owner).getHandle().setPassengerOf(this);
          return true;
        }
 else {
          getMyPet().sendMessageToOwner(Locales.getString("String_Node_Str",myPet.getOwner().getLanguage()));
        }
      }
    }
    if (myPet.getSkills().isSkillActive("String_Node_Str")) {
      if (itemStack.id == de.Keyle.MyPet.skill.skills.implementation.Control.CONTROL_ITEM) {
        return true;
      }
    }
  }
  if (canEat(itemStack) && canUseItem()) {
    if (owner != null && !Permissions.hasExtended(owner,"String_Node_Str")) {
      return false;
    }
    if (this.petTargetSelector.hasGoal("String_Node_Str")) {
      BehaviorDuelTarget duelTarget=(BehaviorDuelTarget)this.petTargetSelector.getGoal("String_Node_Str");
      if (duelTarget.getDuelOpponent() != null) {
        return true;
      }
    }
    int addHunger=Configuration.HUNGER_SYSTEM_POINTS_PER_FEED;
    if (getHealth() < getMaxHealth()) {
      if (!entityhuman.abilities.canInstantlyBuild) {
        --itemStack.count;
      }
      addHunger-=Math.min(3,getMaxHealth() - getHealth()) * 2;
      this.heal(Math.min(3,getMaxHealth() - getHealth()),RegainReason.EATING);
      if (itemStack.count <= 0) {
        entityhuman.inventory.setItem(entityhuman.inventory.itemInHandIndex,null);
      }
      BukkitUtil.playParticleEffect(myPet.getLocation().add(0,MyPet.getEntitySize(this.getClass())[0] + 0.15,0),"String_Node_Str",0.5F,0.5F,0.5F,0.5F,5,20);
    }
 else     if (myPet.getHungerValue() < 100) {
      if (!entityhuman.abilities.canInstantlyBuild) {
        --itemStack.count;
      }
      if (itemStack.count <= 0) {
        entityhuman.inventory.setItem(entityhuman.inventory.itemInHandIndex,null);
      }
      BukkitUtil.playParticleEffect(myPet.getLocation().add(0,MyPet.getEntitySize(this.getClass())[0] + 0.15,0),"String_Node_Str",0.5F,0.5F,0.5F,0.5F,5,20);
    }
    if (addHunger > 0 && myPet.getHungerValue() < 100) {
      myPet.setHungerValue(myPet.getHungerValue() + addHunger);
      addHunger=0;
    }
    if (addHunger < Configuration.HUNGER_SYSTEM_POINTS_PER_FEED) {
      return true;
    }
  }
  return false;
}

Fixed version (ground truth):
/** 
 * Is called when player rightclicks this MyPet return: true: there was a reaction on rightclick false: no reaction on rightclick
 */
public boolean handlePlayerInteraction(EntityHuman entityhuman){
  ItemStack itemStack=entityhuman.inventory.getItemInHand();
  Player owner=this.getOwner().getPlayer();
  applyLeash();
  if (isMyPet() && myPet.getOwner().equals(entityhuman)) {
    if (myPet.getSkills().isSkillActive("String_Node_Str")) {
      if ((itemStack.id == Ride.RIDE_ITEM || (Ride.RIDE_ITEM == 0 && (itemStack == null || itemStack.id == 0))) && canMove()) {
        if (Permissions.hasExtended(owner,"String_Node_Str")) {
          ((CraftPlayer)owner).getHandle().setPassengerOf(this);
          return true;
        }
 else {
          getMyPet().sendMessageToOwner(Locales.getString("String_Node_Str",myPet.getOwner().getLanguage()));
        }
      }
    }
    if (myPet.getSkills().isSkillActive("String_Node_Str")) {
      if (itemStack.id == de.Keyle.MyPet.skill.skills.implementation.Control.CONTROL_ITEM) {
        return true;
      }
    }
  }
  if (canEat(itemStack) && canUseItem()) {
    if (owner != null && !Permissions.hasExtended(owner,"String_Node_Str")) {
      return false;
    }
    if (this.petTargetSelector.hasGoal("String_Node_Str")) {
      BehaviorDuelTarget duelTarget=(BehaviorDuelTarget)this.petTargetSelector.getGoal("String_Node_Str");
      if (duelTarget.getDuelOpponent() != null) {
        return true;
      }
    }
    int addHunger=Configuration.HUNGER_SYSTEM_POINTS_PER_FEED;
    if (getHealth() < getMaxHealth()) {
      if (!entityhuman.abilities.canInstantlyBuild) {
        --itemStack.count;
      }
      addHunger-=Math.min(3,getMaxHealth() - getHealth()) * 2;
      this.heal(Math.min(3,getMaxHealth() - getHealth()),RegainReason.EATING);
      if (itemStack.count <= 0) {
        entityhuman.inventory.setItem(entityhuman.inventory.itemInHandIndex,null);
      }
      BukkitUtil.playParticleEffect(myPet.getLocation().add(0,MyPet.getEntitySize(this.getClass())[0] + 0.15,0),"String_Node_Str",0.5F,0.5F,0.5F,0.5F,5,20);
    }
 else     if (myPet.getHungerValue() < 100) {
      if (!entityhuman.abilities.canInstantlyBuild) {
        --itemStack.count;
      }
      if (itemStack.count <= 0) {
        entityhuman.inventory.setItem(entityhuman.inventory.itemInHandIndex,null);
      }
      BukkitUtil.playParticleEffect(myPet.getLocation().add(0,MyPet.getEntitySize(this.getClass())[0] + 0.15,0),"String_Node_Str",0.5F,0.5F,0.5F,0.5F,5,20);
    }
    if (addHunger > 0 && myPet.getHungerValue() < 100) {
      myPet.setHungerValue(myPet.getHungerValue() + addHunger);
      addHunger=0;
    }
    if (addHunger < Configuration.HUNGER_SYSTEM_POINTS_PER_FEED) {
      return true;
    }
  }
  return false;
}