Program: 34775
Project: 34775
Buggy source:
/** 
 * Helper method to process a SETTINGS frame received from the client. Since the protocol utilizes SETTINGS frames for initialization, some special logic is needed.
 */
private void processSETTINGSFrame(){
  if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
    Tr.debug(tc,"String_Node_Str");
  }
  if (!connection_preface_settings_rcvd && !((FrameSettings)currentFrame).flagAckSet()) {
    connection_preface_settings_rcvd=true;
  }
  if (((FrameSettings)currentFrame).flagAckSet()) {
    if (!connection_preface_settings_ack_rcvd) {
      connection_preface_settings_ack_rcvd=true;
    }
  }
 else {
    if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
      Tr.debug(tc,"String_Node_Str");
    }
    if (((FrameSettings)currentFrame).getInitialWindowSize() != -1) {
      int newSize=((FrameSettings)currentFrame).getInitialWindowSize();
      muxLink.changeInitialWindowSizeAllStreams(newSize);
    }
    muxLink.getConnectionSettings().updateSettings((FrameSettings)currentFrame);
    currentFrame=new FrameSettings();
    currentFrame.setAckFlag();
    try {
      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
        Tr.debug(tc,"String_Node_Str" + myID + "String_Node_Str"+ currentFrame.getFrameType().toString()+ "String_Node_Str"+ Direction.WRITING_OUT+ "String_Node_Str"+ muxLink.hashCode());
      }
      writeFrameSync();
    }
 catch (    FlowControlException e) {
      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
        Tr.debug(tc,"String_Node_Str" + e);
      }
    }
  }
  if (connection_preface_settings_rcvd && connection_preface_settings_ack_rcvd) {
    if (muxLink.checkInitAndOpen()) {
      muxLink.initLock.countDown();
    }
  }
}

Fixed version (ground truth):
/** 
 * Helper method to process a SETTINGS frame received from the client. Since the protocol utilizes SETTINGS frames for initialization, some special logic is needed.
 */
private void processSETTINGSFrame(){
  if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
    Tr.debug(tc,"String_Node_Str" + currentFrame.toString());
  }
  if (!connection_preface_settings_rcvd && !((FrameSettings)currentFrame).flagAckSet()) {
    connection_preface_settings_rcvd=true;
  }
  if (((FrameSettings)currentFrame).flagAckSet()) {
    if (!connection_preface_settings_ack_rcvd) {
      connection_preface_settings_ack_rcvd=true;
    }
  }
 else {
    if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
      Tr.debug(tc,"String_Node_Str");
    }
    if (((FrameSettings)currentFrame).getInitialWindowSize() != -1) {
      int newSize=((FrameSettings)currentFrame).getInitialWindowSize();
      muxLink.changeInitialWindowSizeAllStreams(newSize);
    }
    muxLink.getConnectionSettings().updateSettings((FrameSettings)currentFrame);
    currentFrame=new FrameSettings();
    currentFrame.setAckFlag();
    try {
      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
        Tr.debug(tc,"String_Node_Str" + myID + "String_Node_Str"+ currentFrame.getFrameType().toString()+ "String_Node_Str"+ Direction.WRITING_OUT+ "String_Node_Str"+ muxLink.hashCode());
      }
      writeFrameSync();
    }
 catch (    FlowControlException e) {
      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
        Tr.debug(tc,"String_Node_Str" + e);
      }
    }
  }
  if (connection_preface_settings_rcvd && connection_preface_settings_ack_rcvd) {
    if (muxLink.checkInitAndOpen()) {
      muxLink.initLock.countDown();
    }
  }
}