Program: 46890
Project: 46890
Buggy source:
void processBinaryAnnotations(zipkin.Span source){
  zipkin.Endpoint ca=null, sa=null, ma=null;
  for (int i=0, length=source.binaryAnnotations.size(); i < length; i++) {
    BinaryAnnotation b=source.binaryAnnotations.get(i);
    if (b.type == BOOL) {
      if (Constants.CLIENT_ADDR.equals(b.key)) {
        ca=b.endpoint;
      }
 else       if (Constants.SERVER_ADDR.equals(b.key)) {
        sa=b.endpoint;
      }
 else       if (Constants.MESSAGE_ADDR.equals(b.key)) {
        ma=b.endpoint;
      }
 else {
        forEndpoint(source,b.endpoint).putTag(b.key,b.value[0] == 1 ? "String_Node_Str" : "String_Node_Str");
      }
      continue;
    }
    Span.Builder currentSpan=forEndpoint(source,b.endpoint);
switch (b.type) {
case BOOL:
      break;
case STRING:
    if (Constants.LOCAL_COMPONENT.equals(b.key) && b.value.length == 0)     continue;
  currentSpan.putTag(b.key,new String(b.value,Util.UTF_8));
break;
case BYTES:
currentSpan.putTag(b.key,writeBase64Url(b.value));
break;
case I16:
currentSpan.putTag(b.key,Short.toString(ByteBuffer.wrap(b.value).getShort()));
break;
case I32:
currentSpan.putTag(b.key,Integer.toString(ByteBuffer.wrap(b.value).getInt()));
break;
case I64:
currentSpan.putTag(b.key,Long.toString(ByteBuffer.wrap(b.value).getLong()));
break;
case DOUBLE:
double wrapped=Double.longBitsToDouble(ByteBuffer.wrap(b.value).getLong());
currentSpan.putTag(b.key,Double.toString(wrapped));
break;
}
}
if (cs != null && sa != null && !closeEnough(sa,cs.endpoint)) {
forEndpoint(source,cs.endpoint).remoteEndpoint(sa.toV2());
}
if (sr != null && ca != null && !closeEnough(ca,sr.endpoint)) {
forEndpoint(source,sr.endpoint).remoteEndpoint(ca.toV2());
}
if (ms != null && ma != null && !closeEnough(ma,ms.endpoint)) {
forEndpoint(source,ms.endpoint).remoteEndpoint(ma.toV2());
}
if (mr != null && ma != null && !closeEnough(ma,mr.endpoint)) {
forEndpoint(source,mr.endpoint).remoteEndpoint(ma.toV2());
}
if ((cs == null && sr == null) && (ca != null && sa != null)) {
forEndpoint(source,ca).remoteEndpoint(sa.toV2());
}
}

Fixed version (ground truth):
void processBinaryAnnotations(zipkin.Span source){
  zipkin.Endpoint ca=null, sa=null, ma=null;
  for (int i=0, length=source.binaryAnnotations.size(); i < length; i++) {
    BinaryAnnotation b=source.binaryAnnotations.get(i);
    if (b.type == BOOL) {
      if (Constants.CLIENT_ADDR.equals(b.key)) {
        ca=b.endpoint;
      }
 else       if (Constants.SERVER_ADDR.equals(b.key)) {
        sa=b.endpoint;
      }
 else       if (Constants.MESSAGE_ADDR.equals(b.key)) {
        ma=b.endpoint;
      }
 else {
        forEndpoint(source,b.endpoint).putTag(b.key,b.value[0] == 1 ? "String_Node_Str" : "String_Node_Str");
      }
      continue;
    }
    Span.Builder currentSpan=forEndpoint(source,b.endpoint);
switch (b.type) {
case BOOL:
      break;
case STRING:
    if (Constants.LOCAL_COMPONENT.equals(b.key) && b.value.length == 0)     continue;
  currentSpan.putTag(b.key,new String(b.value,Util.UTF_8));
break;
case BYTES:
currentSpan.putTag(b.key,writeBase64Url(b.value));
break;
case I16:
currentSpan.putTag(b.key,Short.toString(ByteBuffer.wrap(b.value).getShort()));
break;
case I32:
currentSpan.putTag(b.key,Integer.toString(ByteBuffer.wrap(b.value).getInt()));
break;
case I64:
currentSpan.putTag(b.key,Long.toString(ByteBuffer.wrap(b.value).getLong()));
break;
case DOUBLE:
double wrapped=Double.longBitsToDouble(ByteBuffer.wrap(b.value).getLong());
currentSpan.putTag(b.key,Double.toString(wrapped));
break;
}
}
if ((cs == null && sr == null) && (ca != null && sa != null)) {
forEndpoint(source,ca).remoteEndpoint(sa.toV2());
return;
}
if (sa != null) {
if (cs != null && !closeEnough(sa,cs.endpoint)) {
forEndpoint(source,cs.endpoint).remoteEndpoint(sa.toV2());
}
 else if (cr != null && !closeEnough(sa,cr.endpoint)) {
forEndpoint(source,cr.endpoint).remoteEndpoint(sa.toV2());
}
 else if (cs == null && cr == null && sr == null && ss == null) {
forEndpoint(source,null).kind(Kind.CLIENT).remoteEndpoint(sa.toV2());
}
}
if (ca != null) {
if (sr != null && !closeEnough(ca,sr.endpoint)) {
forEndpoint(source,sr.endpoint).remoteEndpoint(ca.toV2());
}
if (ss != null && !closeEnough(ca,ss.endpoint)) {
forEndpoint(source,ss.endpoint).remoteEndpoint(ca.toV2());
}
 else if (cs == null && cr == null && sr == null && ss == null) {
forEndpoint(source,null).kind(Kind.SERVER).remoteEndpoint(ca.toV2());
}
}
if (ma != null) {
if (ms != null && !closeEnough(ma,ms.endpoint)) {
forEndpoint(source,ms.endpoint).remoteEndpoint(ma.toV2());
}
if (mr != null && !closeEnough(ma,mr.endpoint)) {
forEndpoint(source,mr.endpoint).remoteEndpoint(ma.toV2());
}
}
}