Program: 5262
Project: 5262
Buggy source:
/** 
 * Convert an object to JSON text. <p> If this object is a Map or a List, and it's also a JSONAware, JSONAware will be considered firstly. <p> DO NOT call this method from toJSONString() of a class that implements both JSONAware and Map or List with  "this" as the parameter, use JSONObject.toJSONString(Map) or JSONArray.toJSONString(List) instead. 
 * @see org.json.simple.JSONObject#toJSONString(Map)
 * @see org.json.simple.JSONArray#toJSONString(List)
 * @param value
 * @return JSON text, or "null" if value is null or it's an NaN or an INF number.
 */
public static String toJSONString(Object value){
  if (value == null)   return "String_Node_Str";
  JSONFormatter formatter=formatters.get(value.getClass());
  if (formatter != null) {
    return formatter.toJSONString(value);
  }
  if (value instanceof String)   return "String_Node_Str" + escape((String)value) + "String_Node_Str";
  if (value instanceof Double) {
    if (((Double)value).isInfinite() || ((Double)value).isNaN())     return "String_Node_Str";
 else     return value.toString();
  }
  if (value instanceof Float) {
    if (((Float)value).isInfinite() || ((Float)value).isNaN())     return "String_Node_Str";
 else     return value.toString();
  }
  if (value instanceof Number)   return value.toString();
  if (value instanceof Boolean)   return value.toString();
  if ((value instanceof JSONAware))   return ((JSONAware)value).toJSONString();
  if (value instanceof Map)   return JSONObject.toJSONString((Map)value);
  if (value instanceof List)   return JSONArray.toJSONString((List)value);
  return value.toString();
}

Fixed version (ground truth):
/** 
 * Convert an object to JSON text. <p> If this object is a Map or a List, and it's also a JSONAware, JSONAware will be considered firstly. <p> DO NOT call this method from toJSONString() of a class that implements both JSONAware and Map or List with  "this" as the parameter, use JSONObject.toJSONString(Map) or JSONArray.toJSONString(List) instead. 
 * @see org.json.simple.JSONObject#toJSONString(Map)
 * @see org.json.simple.JSONArray#toJSONString(List)
 * @param value
 * @return JSON text, or "null" if value is null or it's an NaN or an INF number.
 */
public static String toJSONString(Object value){
  if (value == null)   return "String_Node_Str";
  JSONFormatter formatter=formatters.get(value.getClass());
  if (formatter != null) {
    return formatter.toJSONString(value);
  }
  if (value instanceof String)   return "String_Node_Str" + escape((String)value) + "String_Node_Str";
  if (value instanceof Double) {
    if (((Double)value).isInfinite() || ((Double)value).isNaN())     return "String_Node_Str";
 else     return value.toString();
  }
  if (value instanceof Float) {
    if (((Float)value).isInfinite() || ((Float)value).isNaN())     return "String_Node_Str";
 else     return value.toString();
  }
  if (value instanceof Number)   return value.toString();
  if (value instanceof Boolean)   return value.toString();
  if ((value instanceof JSONAware))   return ((JSONAware)value).toJSONString();
  if (value instanceof Map)   return JSONObject.toJSONString((Map)value);
  if (value instanceof List)   return JSONArray.toJSONString((List)value);
  return toJSONString(value.toString());
}