Program: 15861
Project: 15861
Buggy source:
protected void handleComponentAttached(Component comp){
  boolean removeMark=Boolean.TRUE.equals(comp.getAttribute(REMOVE_MARK));
  if (removeMark) {
    comp.addEventListener(10000,ON_ZKBIND_LATER,new EventListener<Event>(){
      public void onEvent(      Event event) throws Exception {
        final Component comp=event.getTarget();
        comp.removeAttribute(REMOVE_MARK);
        comp.removeEventListener(ON_ZKBIND_LATER,this);
        handleComponentAttached(comp);
      }
    }
);
    Events.postEvent(new Event(ON_ZKBIND_LATER,comp));
    return;
  }
  if (comp.getDesktop() != null) {
    Binder selfBinder=BinderUtil.getBinder(comp);
    if (selfBinder == null) {
      Binder parentBinder=BinderUtil.getBinder(comp,true);
      if (parentBinder != null && (parentBinder instanceof BinderImpl)) {
        comp.addEventListener(10000,BinderImpl.ON_BIND_INIT,new EventListener<Event>(){
          public void onEvent(          Event event) throws Exception {
            final Component comp=event.getTarget();
            comp.removeEventListener(BinderImpl.ON_BIND_INIT,this);
            if (comp.getPage() == null) {
              return;
            }
            final Binder innerBinder=BinderUtil.getBinder(comp);
            if (innerBinder != null) {
              return;
            }
            Binder binder=BinderUtil.getBinder(comp,true);
            if (binder == null) {
              return;
            }
            if (getExtension().isLifeCycleHandling(comp)) {
              return;
            }
            if (binder instanceof AnnotateBinder) {
              new AnnotateBinderHelper(binder).initComponentBindings(comp);
            }
            getExtension().markLifeCycleHandling(comp);
            binder.loadComponent(comp,true);
            if (comp.getAttribute(BinderImpl.VAR) != null)             BinderUtil.markHandling(comp,binder);
          }
        }
);
        Events.postEvent(new Event(BinderImpl.ON_BIND_INIT,comp));
      }
    }
  }
}

Fixed version (ground truth):
protected void handleComponentAttached(Component comp){
  boolean removeMark=Boolean.TRUE.equals(comp.getAttribute(REMOVE_MARK));
  if (removeMark) {
    comp.addEventListener(10000,ON_ZKBIND_LATER,new EventListener<Event>(){
      public void onEvent(      Event event) throws Exception {
        final Component comp=event.getTarget();
        comp.removeAttribute(REMOVE_MARK);
        comp.removeEventListener(ON_ZKBIND_LATER,this);
        handleComponentAttached(comp);
      }
    }
);
    Events.postEvent(new Event(ON_ZKBIND_LATER,comp));
    return;
  }
  if (comp.getDesktop() != null) {
    Binder selfBinder=BinderUtil.getBinder(comp);
    if (selfBinder == null) {
      Binder parentBinder=BinderUtil.getBinder(comp,true);
      if (parentBinder != null && (parentBinder instanceof BinderImpl)) {
        comp.addEventListener(10000,BinderImpl.ON_BIND_INIT,new EventListener<Event>(){
          public void onEvent(          Event event) throws Exception {
            final Component comp=event.getTarget();
            comp.removeEventListener(BinderImpl.ON_BIND_INIT,this);
            if (comp.getPage() == null) {
              if (comp.hasAttribute(BinderImpl.VAR)) {
                Object ref=comp.getAttribute((String)comp.getAttribute(BinderImpl.VAR));
                if (ref instanceof ReferenceBinding) {
                  BinderUtil.markHandling(comp,((ReferenceBinding)ref).getBinder());
                }
              }
              return;
            }
            final Binder innerBinder=BinderUtil.getBinder(comp);
            if (innerBinder != null) {
              return;
            }
            Binder binder=BinderUtil.getBinder(comp,true);
            if (binder == null) {
              return;
            }
            if (getExtension().isLifeCycleHandling(comp)) {
              BinderUtil.markHandling(comp,binder);
              return;
            }
            if (binder instanceof AnnotateBinder) {
              new AnnotateBinderHelper(binder).initComponentBindings(comp);
            }
            getExtension().markLifeCycleHandling(comp);
            binder.loadComponent(comp,true);
            if (comp.hasAttribute(BinderImpl.VAR))             BinderUtil.markHandling(comp,binder);
          }
        }
);
        Events.postEvent(new Event(BinderImpl.ON_BIND_INIT,comp));
      }
    }
  }
}