{"action":"created","issue":{"url":"https://api.github.com/repos/17mon/java/issues/6","labels_url":"https://api.github.com/repos/17mon/java/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/17mon/java/issues/6/comments","events_url":"https://api.github.com/repos/17mon/java/issues/6/events","html_url":"https://github.com/17mon/java/issues/6","id":97964289,"number":6,"title":"IndexOutOfBoundsException in IPExt test","user":{"login":"yiming187","id":1217700,"avatar_url":"https://avatars.githubusercontent.com/u/1217700?v=3","gravatar_id":"","url":"https://api.github.com/users/yiming187","html_url":"https://github.com/yiming187","followers_url":"https://api.github.com/users/yiming187/followers","following_url":"https://api.github.com/users/yiming187/following{/other_user}","gists_url":"https://api.github.com/users/yiming187/gists{/gist_id}","starred_url":"https://api.github.com/users/yiming187/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yiming187/subscriptions","organizations_url":"https://api.github.com/users/yiming187/orgs","repos_url":"https://api.github.com/users/yiming187/repos","events_url":"https://api.github.com/users/yiming187/events{/privacy}","received_events_url":"https://api.github.com/users/yiming187/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-29T15:37:20Z","updated_at":"2016-01-07T05:16:06Z","closed_at":null,"body":"I just downloaded the source code and data file. The IP.java runs very well, but the IPExt.java met some errors. Do you have any idea?\r\n\r\n\tpublic static void main(String[] args) {\r\n\t\tIPExt.load(\"data/17monipdb.dat\");\r\n\r\n\t\tSystem.out.println(Arrays.toString(IPExt.find(\"8.8.8.8\")));\r\n\t\tSystem.out.println(Arrays.toString(IPExt.find(\"118.28.8.8\")));\r\n\t\tSystem.out.println(Arrays.toString(IPExt.find(\"255.255.255.255\")));\r\n\t}\r\n``\r\nException in thread \"main\" java.lang.IndexOutOfBoundsException\r\n\tat java.nio.Buffer.checkIndex(Buffer.java:546)\r\n\tat java.nio.HeapByteBuffer.getInt(HeapByteBuffer.java:365)\r\n\tat com.yiming187.jnetpcap_example.ip.IPExt.find(IPExt.java:66)\r\n\tat com.yiming187.jnetpcap_example.ip.IPExt.main(IPExt.java:18)``"},"comment":{"url":"https://api.github.com/repos/17mon/java/issues/comments/169553409","html_url":"https://github.com/17mon/java/issues/6#issuecomment-169553409","issue_url":"https://api.github.com/repos/17mon/java/issues/6","id":169553409,"user":{"login":"17mon","id":7857663,"avatar_url":"https://avatars.githubusercontent.com/u/7857663?v=3","gravatar_id":"","url":"https://api.github.com/users/17mon","html_url":"https://github.com/17mon","followers_url":"https://api.github.com/users/17mon/followers","following_url":"https://api.github.com/users/17mon/following{/other_user}","gists_url":"https://api.github.com/users/17mon/gists{/gist_id}","starred_url":"https://api.github.com/users/17mon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/17mon/subscriptions","organizations_url":"https://api.github.com/users/17mon/orgs","repos_url":"https://api.github.com/users/17mon/repos","events_url":"https://api.github.com/users/17mon/events{/privacy}","received_events_url":"https://api.github.com/users/17mon/received_events","type":"User","site_admin":false},"created_at":"2016-01-07T05:16:06Z","updated_at":"2016-01-07T05:16:06Z","body":"IPExt 只支持datx格式的文件不支持dat格式"}}