Program: 94656
Project: 94656
Buggy source:
public ArduSolo(String droneId,Context context,DataLink.DataLinkProvider<MAVLinkMessage> mavClient,Handler handler,AutopilotWarningParser warningParser,LogMessageListener logListener){
  super(droneId,context,mavClient,handler,warningParser,logListener);
  this.propertyType=new Type(Type.TYPE_SOLO,getFirmwareVersion());
  this.soloComp=new SoloComp(context,handler);
  this.soloComp.setListener(new SoloComp.SoloCompListener(){
    @Override public void onConnected(){
      if (isConnected()) {
        notifyDroneEvent(DroneInterfaces.DroneEventsType.CONNECTED);
      }
    }
    @Override public void onDisconnected(){
      notifyDroneEvent(DroneInterfaces.DroneEventsType.DISCONNECTED);
    }
    @Override public void onTlvPacketReceived(    TLVPacket packet){
switch (packet.getMessageType()) {
case TLVMessageTypes.TYPE_ARTOO_INPUT_REPORT_MESSAGE:
        break;
case TLVMessageTypes.TYPE_SOLO_GET_BUTTON_SETTING:
case TLVMessageTypes.TYPE_SOLO_SET_BUTTON_SETTING:
      break;
case TLVMessageTypes.TYPE_SOLO_GOPRO_STATE:
    notifyAttributeListener(SoloEvents.SOLO_GOPRO_STATE_UPDATED);
  break;
case TLVMessageTypes.TYPE_SOLO_GOPRO_STATE_V2:
notifyAttributeListener(SoloEvents.SOLO_GOPRO_STATE_V2_UPDATED);
break;
default :
final Bundle messageInfo=new Bundle();
messageInfo.putParcelable(SoloEventExtras.EXTRA_SOLO_MESSAGE_DATA,packet);
notifyAttributeListener(SoloEvents.SOLO_MESSAGE_RECEIVED,messageInfo);
break;
}
}
@Override public void onPresetButtonLoaded(int buttonType,SoloButtonSetting buttonSettings){
notifyAttributeListener(SoloEvents.SOLO_BUTTON_SETTINGS_UPDATED,null);
}
@Override public void onWifiInfoUpdated(String wifiName,String wifiPassword){
notifyAttributeListener(SoloEvents.SOLO_WIFI_SETTINGS_UPDATED,null);
}
@Override public void onButtonPacketReceived(ButtonPacket packet){
final Bundle eventInfo=new Bundle();
eventInfo.putParcelable(SoloEventExtras.EXTRA_SOLO_BUTTON_EVENT,packet);
notifyAttributeListener(SoloEvents.SOLO_BUTTON_EVENT_RECEIVED,eventInfo);
}
@Override public void onTxPowerComplianceCountryUpdated(String compliantCountry){
final Bundle eventInfo=new Bundle(1);
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_TX_POWER_COMPLIANT_COUNTRY,compliantCountry);
notifyAttributeListener(SoloEvents.SOLO_TX_POWER_COMPLIANCE_COUNTRY_UPDATED,eventInfo);
}
@Override public void onVersionsUpdated(){
final Bundle eventInfo=new Bundle();
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_VEHICLE_VERSION,soloComp.getVehicleVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_AUTOPILOT_VERSION,soloComp.getAutopilotVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_GIMBAL_VERSION,soloComp.getGimbalVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_CONTROLLER_VERSION,soloComp.getControllerVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_CONTROLLER_FIRMWARE_VERSION,soloComp.getControllerFirmwareVersion());
notifyAttributeListener(SoloEvents.SOLO_VERSIONS_UPDATED,eventInfo);
}
@Override public void onControllerEvent(String event,Bundle eventInfo){
notifyAttributeListener(event,eventInfo);
}
}
);
}

Fixed version (ground truth):
public ArduSolo(String droneId,Context context,DataLink.DataLinkProvider<MAVLinkMessage> mavClient,Handler handler,AutopilotWarningParser warningParser,LogMessageListener logListener){
  super(droneId,context,mavClient,handler,warningParser,logListener);
  this.soloComp=new SoloComp(context,handler);
  this.soloComp.setListener(new SoloComp.SoloCompListener(){
    @Override public void onConnected(){
      if (isConnected()) {
        notifyDroneEvent(DroneInterfaces.DroneEventsType.CONNECTED);
      }
    }
    @Override public void onDisconnected(){
      notifyDroneEvent(DroneInterfaces.DroneEventsType.DISCONNECTED);
    }
    @Override public void onTlvPacketReceived(    TLVPacket packet){
switch (packet.getMessageType()) {
case TLVMessageTypes.TYPE_ARTOO_INPUT_REPORT_MESSAGE:
        break;
case TLVMessageTypes.TYPE_SOLO_GET_BUTTON_SETTING:
case TLVMessageTypes.TYPE_SOLO_SET_BUTTON_SETTING:
      break;
case TLVMessageTypes.TYPE_SOLO_GOPRO_STATE:
    notifyAttributeListener(SoloEvents.SOLO_GOPRO_STATE_UPDATED);
  break;
case TLVMessageTypes.TYPE_SOLO_GOPRO_STATE_V2:
notifyAttributeListener(SoloEvents.SOLO_GOPRO_STATE_V2_UPDATED);
break;
default :
final Bundle messageInfo=new Bundle();
messageInfo.putParcelable(SoloEventExtras.EXTRA_SOLO_MESSAGE_DATA,packet);
notifyAttributeListener(SoloEvents.SOLO_MESSAGE_RECEIVED,messageInfo);
break;
}
}
@Override public void onPresetButtonLoaded(int buttonType,SoloButtonSetting buttonSettings){
notifyAttributeListener(SoloEvents.SOLO_BUTTON_SETTINGS_UPDATED,null);
}
@Override public void onWifiInfoUpdated(String wifiName,String wifiPassword){
notifyAttributeListener(SoloEvents.SOLO_WIFI_SETTINGS_UPDATED,null);
}
@Override public void onButtonPacketReceived(ButtonPacket packet){
final Bundle eventInfo=new Bundle();
eventInfo.putParcelable(SoloEventExtras.EXTRA_SOLO_BUTTON_EVENT,packet);
notifyAttributeListener(SoloEvents.SOLO_BUTTON_EVENT_RECEIVED,eventInfo);
}
@Override public void onTxPowerComplianceCountryUpdated(String compliantCountry){
final Bundle eventInfo=new Bundle(1);
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_TX_POWER_COMPLIANT_COUNTRY,compliantCountry);
notifyAttributeListener(SoloEvents.SOLO_TX_POWER_COMPLIANCE_COUNTRY_UPDATED,eventInfo);
}
@Override public void onVersionsUpdated(){
final Bundle eventInfo=new Bundle();
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_VEHICLE_VERSION,soloComp.getVehicleVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_AUTOPILOT_VERSION,soloComp.getAutopilotVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_GIMBAL_VERSION,soloComp.getGimbalVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_CONTROLLER_VERSION,soloComp.getControllerVersion());
eventInfo.putString(SoloEventExtras.EXTRA_SOLO_CONTROLLER_FIRMWARE_VERSION,soloComp.getControllerFirmwareVersion());
notifyAttributeListener(SoloEvents.SOLO_VERSIONS_UPDATED,eventInfo);
}
@Override public void onControllerEvent(String event,Bundle eventInfo){
notifyAttributeListener(event,eventInfo);
}
}
);
}