[Demonstration 1]

[Buggy Method]
@Override
public void onBindViewHolder(RecyclerView.ViewHolder viewHolder, int i) {
    VplanObject obj = vplanEntries.get(i);
    // if this is the vplan_info_view
    if (obj instanceof VplanInfo) {
        VPlanInfoViewHolder vPlanInfoViewHolder = (VPlanInfoViewHolder) viewHolder;
        // get entries and construct String
        String string_info = "Keine Informationen gespeichert";
        for (int j = 0; j < ((VplanInfo) obj).getInfos().size(); j++) {
            string_info = ((VplanInfo) obj).getInfos().get(j) + System.getProperty("line.separator");
        }
        vPlanInfoViewHolder.info.setText(string_info);
    } else {
        // cast to VPlanViewHolder
        VplanEntry entry = (VplanEntry) obj;
        VPlanViewHolder vPlanViewHolder = (VPlanViewHolder) viewHolder;
        // get elements from vplanEntries class
        String lesson = entry.getLessons();
        String school_class = entry.getGrade();
        String regular = entry.getPlan();
        String comment = entry.getComment();
        String substitution = entry.getSubstitution();
        // only display school class in entry cards, if user is no pupil (and has more than
        // only his own class's entries)
        if (!multiClass) {
            vPlanViewHolder.schoolClassText.setText(school_class);
        }
        // display entries
        vPlanViewHolder.lessonText.setText(lesson);
        vPlanViewHolder.regularText.setText(regular);
        vPlanViewHolder.substitutionText.setText(substitution);
        vPlanViewHolder.substitutionText.setText(comment);
    }
}

[Buggy Hunk]
vPlanViewHolder.substitutionText.setText(comment);

[Patch]
vPlanViewHolder.commentText.setText(comment);

[Demonstration 2]

[Buggy Method]
@RequestMapping(value = "/avatar/{profileId}", method = RequestMethod.POST)
@ResponseBody
public Profile getProfileAvatar(MultipartHttpServletRequest request, HttpServletResponse response, @PathVariable("profileId") String profileId) throws IOException, ProfileException {
    final Profile profile = SocialSecurityUtils.getCurrentProfile();
    if (profile != null && !profile.getUsername().equalsIgnoreCase(SocialSecurityUtils.ANONYMOUS)) {
        final Iterator<String> files = request.getFileNames();
        String fileName = null;
        if (files.hasNext()) {
            fileName = files.next();
        }
        if (!StringUtils.isBlank(fileName)) {
            final MultipartFile avatar = request.getFile(fileName);
            profileService.addProfileAttachment(profile.getId().toString(), AVATAR + "." + FilenameUtils.getExtension(avatar.getOriginalFilename()), avatar.getInputStream());
        }
        return profile;
    } else {
        response.setStatus(HttpServletResponse.SC_BAD_REQUEST);
        return null;
    }
}

[Buggy Hunk]
.getExtension(avatar.getOriginalFilename()), avatar.getInputStream());

[Patch]
.getExtension(avatar.getOriginalFilename()).toLowerCase(), avatar.getInputStream());

[Demonstration 3]

[Buggy Method]
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
    Intent intent = new Intent(getBaseContext(), TestWaresList.class);
    intent.putExtra(ShoppingListDetail.EXTRA_LISTNO, list_id);
    intent.putExtra(TestWaresList.EXTRA_STORE_ID, (int) id - 1);
    startActivity(intent);
}

[Buggy Hunk]
intent.putExtra(TestWaresList.EXTRA_STORE_ID, (int) id - 1);

[Patch]
intent.putExtra(TestWaresList.EXTRA_STORE_ID, (int) id );