# This patch file was generated by NetBeans IDE # Following Index: paths are relative to: /home/theofanis/repositories/core-main # This patch can be applied using context Tools: Patch action on respective folder. # It uses platform neutral UTF-8 encoding and \n newlines. # Above lines and this line are ignored by the patching process. Index: tasklist.todo/src/org/netbeans/modules/tasklist/todo/TodoTaskScanner.java --- tasklist.todo/src/org/netbeans/modules/tasklist/todo/TodoTaskScanner.java +++ tasklist.todo/src/org/netbeans/modules/tasklist/todo/TodoTaskScanner.java @@ -379,6 +379,10 @@ if (len == -1) break; sb.append(buf, 0, len); } + } catch(IllegalArgumentException ex) { // reading of extra characters into the specified character buffer failed + Logger.getLogger(TodoTaskScanner.class.getName()).log(Level.INFO, "Reading failed for {0}, with charset: {1}.", new Object[]{FileUtil.toFile(fileObject).getPath(), charset}); //NOI18N; + r.close(); + return ""; } finally { r.close(); }