Program: 15417
Project: 15417
Buggy source:
public void onReceive(Context context,Intent intent){
  boolean notificationsEnabled=PrefsUtility.pref_behaviour_notifications(context,PreferenceManager.getDefaultSharedPreferences(context));
  if (!notificationsEnabled)   return;
  final RedditAccount user=RedditAccountManager.getInstance(context).getDefaultAccount();
  final CacheManager cm=CacheManager.getInstance(context);
  final URI url;
  url=Constants.Reddit.getUri("String_Node_Str");
  request=new CacheRequest(url,user,null,Constants.Priority.API_INBOX_LIST,0,CacheRequest.DownloadType.FORCE,Constants.FileType.INBOX_LIST,true,true,true,context){
    @Override protected void onDownloadNecessary(){
    }
    @Override protected void onDownloadStarted(){
    }
    @Override protected void onCallbackException(    final Throwable t){
      request=null;
      BugReportActivity.handleGlobalError(context,t);
    }
    @Override protected void onFailure(    final RequestFailureType type,    final Throwable t,    final StatusLine status,    final String readableMessage){
    }
    @Override protected void onProgress(    final long bytesRead,    final long totalBytes){
    }
    @Override protected void onSuccess(    final CacheManager.ReadableCacheFile cacheFile,    final long timestamp,    final UUID session,    final boolean fromCache,    final String mimetype){
      request=null;
    }
    @Override public void onJsonParseStarted(    final JsonValue value,    final long timestamp,    final UUID session,    final boolean fromCache){
      try {
        final JsonBufferedObject root=value.asObject();
        final JsonBufferedObject data=root.getObject("String_Node_Str");
        final JsonBufferedArray children=data.getArray("String_Node_Str");
        try {
          JsonValue newMessage=children.get(0);
          int numMessages=children.getCurrentItemCount();
          RedditThing thing=newMessage.asObject(RedditThing.class);
          String title;
          String text=context.getString(R.string.notification_message_action);
          String messageID;
switch (thing.getKind()) {
case COMMENT:
            final RedditComment comment=thing.asComment();
          title=comment.author + "String_Node_Str" + context.getString(R.string.notification_comment);
        messageID=comment.name;
      break;
case MESSAGE:
    final RedditMessage message=thing.asMessage();
  title=message.author + "String_Node_Str" + context.getString(R.string.notification_message);
messageID=message.name;
break;
default :
throw new RuntimeException("String_Node_Str");
}
android.content.SharedPreferences messageStore=context.getSharedPreferences(PREFS_FILENAME,0);
String oldMessage=messageStore.getString(PREFS_SAVED_MESSAGE,"String_Node_Str");
if (messageID.equals(oldMessage)) return;
messageStore.edit().putString(PREFS_SAVED_MESSAGE,newMessage.toString()).commit();
if (numMessages > 1) {
title=context.getString(R.string.notification_message_multiple);
}
createNotification(title,text,context);
}
 catch (IndexOutOfBoundsException e) {
}
}
 catch (Throwable t) {
notifyFailure(RequestFailureType.PARSE,t,null,"String_Node_Str");
}
}
}
;
cm.makeRequest(request);
}

Fixed version (ground truth):
public void onReceive(Context context,Intent intent){
  boolean notificationsEnabled=PrefsUtility.pref_behaviour_notifications(context,PreferenceManager.getDefaultSharedPreferences(context));
  if (!notificationsEnabled)   return;
  final RedditAccount user=RedditAccountManager.getInstance(context).getDefaultAccount();
  final CacheManager cm=CacheManager.getInstance(context);
  final URI url;
  url=Constants.Reddit.getUri("String_Node_Str");
  request=new CacheRequest(url,user,null,Constants.Priority.API_INBOX_LIST,0,CacheRequest.DownloadType.FORCE,Constants.FileType.INBOX_LIST,true,true,true,context){
    @Override protected void onDownloadNecessary(){
    }
    @Override protected void onDownloadStarted(){
    }
    @Override protected void onCallbackException(    final Throwable t){
      request=null;
      BugReportActivity.handleGlobalError(context,t);
    }
    @Override protected void onFailure(    final RequestFailureType type,    final Throwable t,    final StatusLine status,    final String readableMessage){
    }
    @Override protected void onProgress(    final long bytesRead,    final long totalBytes){
    }
    @Override protected void onSuccess(    final CacheManager.ReadableCacheFile cacheFile,    final long timestamp,    final UUID session,    final boolean fromCache,    final String mimetype){
      request=null;
    }
    @Override public void onJsonParseStarted(    final JsonValue value,    final long timestamp,    final UUID session,    final boolean fromCache){
      try {
        final JsonBufferedObject root=value.asObject();
        final JsonBufferedObject data=root.getObject("String_Node_Str");
        final JsonBufferedArray children=data.getArray("String_Node_Str");
        try {
          JsonValue newMessage=children.get(0);
          int numMessages=children.getCurrentItemCount();
          RedditThing thing=newMessage.asObject(RedditThing.class);
          String title;
          String text=context.getString(R.string.notification_message_action);
          String messageID;
switch (thing.getKind()) {
case COMMENT:
            final RedditComment comment=thing.asComment();
          title=comment.author + "String_Node_Str" + context.getString(R.string.notification_comment);
        messageID=comment.name;
      break;
case MESSAGE:
    final RedditMessage message=thing.asMessage();
  title=message.author + "String_Node_Str" + context.getString(R.string.notification_message);
messageID=message.name;
break;
default :
throw new RuntimeException("String_Node_Str");
}
android.content.SharedPreferences messageStore=context.getSharedPreferences(PREFS_FILENAME,0);
String oldMessage=messageStore.getString(PREFS_SAVED_MESSAGE,"String_Node_Str");
if (messageID.equals(oldMessage)) return;
messageStore.edit().putString(PREFS_SAVED_MESSAGE,messageID).commit();
if (numMessages > 1) {
title=context.getString(R.string.notification_message_multiple);
}
createNotification(title,text,context);
}
 catch (IndexOutOfBoundsException e) {
}
}
 catch (Throwable t) {
notifyFailure(RequestFailureType.PARSE,t,null,"String_Node_Str");
}
}
}
;
cm.makeRequest(request);
}