{"action":"created","issue":{"url":"https://api.github.com/repos/DMOJ/judge/issues/53","labels_url":"https://api.github.com/repos/DMOJ/judge/issues/53/labels{/name}","comments_url":"https://api.github.com/repos/DMOJ/judge/issues/53/comments","events_url":"https://api.github.com/repos/DMOJ/judge/issues/53/events","html_url":"https://github.com/DMOJ/judge/issues/53","id":84339691,"number":53,"title":"Java executor deadlock","user":{"login":"Xyene","id":1403503,"avatar_url":"https://avatars.githubusercontent.com/u/1403503?v=3","gravatar_id":"","url":"https://api.github.com/users/Xyene","html_url":"https://github.com/Xyene","followers_url":"https://api.github.com/users/Xyene/followers","following_url":"https://api.github.com/users/Xyene/following{/other_user}","gists_url":"https://api.github.com/users/Xyene/gists{/gist_id}","starred_url":"https://api.github.com/users/Xyene/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xyene/subscriptions","organizations_url":"https://api.github.com/users/Xyene/orgs","repos_url":"https://api.github.com/users/Xyene/repos","events_url":"https://api.github.com/users/Xyene/events{/privacy}","received_events_url":"https://api.github.com/users/Xyene/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/DMOJ/judge/labels/bug","name":"bug","color":"fc2929"},{"url":"https://api.github.com/repos/DMOJ/judge/labels/executors","name":"executors","color":"fbca04"}],"state":"open","locked":false,"assignee":{"login":"Xyene","id":1403503,"avatar_url":"https://avatars.githubusercontent.com/u/1403503?v=3","gravatar_id":"","url":"https://api.github.com/users/Xyene","html_url":"https://github.com/Xyene","followers_url":"https://api.github.com/users/Xyene/followers","following_url":"https://api.github.com/users/Xyene/following{/other_user}","gists_url":"https://api.github.com/users/Xyene/gists{/gist_id}","starred_url":"https://api.github.com/users/Xyene/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xyene/subscriptions","organizations_url":"https://api.github.com/users/Xyene/orgs","repos_url":"https://api.github.com/users/Xyene/repos","events_url":"https://api.github.com/users/Xyene/events{/privacy}","received_events_url":"https://api.github.com/users/Xyene/received_events","type":"User","site_admin":false},"milestone":null,"comments":8,"created_at":"2015-06-03T03:43:02Z","updated_at":"2015-06-04T00:56:15Z","closed_at":null,"body":"On Excalibur and Durandal, a user submission for DMPG '15 S5 - Black and White murders the Java executor with an infinitely long grading time.\r\n\r\n```\r\nroot@onlinejudge2:~# java -version\r\njava version \"1.7.0_65\"\r\nOpenJDK Runtime Environment (IcedTea 2.5.1) (7u65-2.5.1-5~deb7u1)\r\nOpenJDK 64-Bit Server VM (build 24.65-b04, mixed mode)\r\n```\r\n\r\n```\r\nroot@onlinejudge2:~# uname -a\r\nLinux onlinejudge2 3.2.0-4-amd64 #1 SMP Debian 3.2.63-2+deb7u1 x86_64 GNU/Linux\r\n```\r\n\r\nThe offending submission:\r\n\r\n```java\r\nimport java.io.*;\r\nimport java.util.*;\r\n\r\npublic class S5\r\n{\r\n   public static void main (String[] args)\r\n   {\r\n      try\r\n      {\r\n         int n =0, m = 0;\r\n      \r\n         int[] x = new int[m];\r\n         int[] y = new int[m];\r\n         int[] w = new int[m];\r\n         int[] h = new int[m];\r\n         \r\n         boolean[][] cells;\r\n         BufferedReader br = new BufferedReader (new InputStreamReader(System.in));\r\n      \r\n         String temp = \"\";\r\n         temp = br.readLine();\r\n         n = Integer.parseInt(temp.split(\" \")[0]);\r\n         cells = new boolean[n][n];\r\n         m = Integer.parseInt(temp.split(\" \")[1]);\r\n         x = new int[m];\r\n         y = new int[m];\r\n         w = new int[m];\r\n         h = new int[m];\r\n         for (int i = 0; i < m; i++)\r\n         {\r\n         \r\n            temp = br.readLine();\r\n            x[i] = Integer.parseInt(temp.split(\" \")[0]);\r\n            y[i] = Integer.parseInt(temp.split(\" \")[1]);\r\n            w[i] = Integer.parseInt(temp.split(\" \")[2]);\r\n            h[i] = Integer.parseInt(temp.split(\" \")[3]);\r\n         }\r\n         \r\n      \r\n         for (int i = 0; i < n; i++)\r\n         {\r\n            for (int k = 0; k <n; k++)\r\n            {\r\n               cells[i][k] = false;\r\n            }\r\n         \r\n         }\r\n      \r\n         for (int com = 0; com < m; com++)\r\n         {\r\n            for (int i = x[com]; i < (x[com] + w[com]); i++)\r\n            {\r\n               for (int k = y[com]; k <y[com] + h[com]; k++)\r\n               {\r\n                  cells[i][k] = !cells[i][k];\r\n               }\r\n            }\r\n         }\r\n      \r\n         int count = 0;\r\n      \r\n         for (int i = 0; i < n; i++)\r\n         {\r\n            for (int k = 0; k < n; k++)\r\n            {\r\n               if (cells[i][k] == true)\r\n               {\r\n                  count++;\r\n               }\r\n            }\r\n         }\r\n      \r\n         System.out.println(count);\r\n      }\r\n      catch (IOException ioe)\r\n      {\r\n      }\r\n   }\r\n\r\n}\r\n```\r\n\r\nSubmission abortion continues to work, however."},"comment":{"url":"https://api.github.com/repos/DMOJ/judge/issues/comments/108662472","html_url":"https://github.com/DMOJ/judge/issues/53#issuecomment-108662472","issue_url":"https://api.github.com/repos/DMOJ/judge/issues/53","id":108662472,"user":{"login":"Xyene","id":1403503,"avatar_url":"https://avatars.githubusercontent.com/u/1403503?v=3","gravatar_id":"","url":"https://api.github.com/users/Xyene","html_url":"https://github.com/Xyene","followers_url":"https://api.github.com/users/Xyene/followers","following_url":"https://api.github.com/users/Xyene/following{/other_user}","gists_url":"https://api.github.com/users/Xyene/gists{/gist_id}","starred_url":"https://api.github.com/users/Xyene/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xyene/subscriptions","organizations_url":"https://api.github.com/users/Xyene/orgs","repos_url":"https://api.github.com/users/Xyene/repos","events_url":"https://api.github.com/users/Xyene/events{/privacy}","received_events_url":"https://api.github.com/users/Xyene/received_events","type":"User","site_admin":false},"created_at":"2015-06-04T00:56:15Z","updated_at":"2015-06-04T00:56:15Z","body":"Never thought `System.exit` could fail: https://github.com/DMOJ/judge/blob/master/java_executor/src/ca/dmoj/java/JavaSafeExecutor.java#L115"}}